/*
 * Copyright (c) Hunan Goke,Chengdu Goke,Shandong Goke. 2021. All rights reserved.
 */
#include <stdio.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <sys/ioctl.h>
#include <fcntl.h>
#include <unistd.h>

#include "comm_video.h"
#include "sns_ctrl.h"

#ifdef GPIO_I2C
#include "gpioi2c_ex.h"
#else
#include "i2c.h"
#endif

const unsigned char ov2718_i2c_addr     =    0x6c; /* I2C Address */
const unsigned int  ov2718_addr_byte    =    2;
const unsigned int  ov2718_data_byte    =    1;
static int g_fd[ISP_MAX_PIPE_NUM] = {[0 ...(ISP_MAX_PIPE_NUM - 1)] = -1};

extern ISP_SNS_STATE_S       *g_pastOv2718[ISP_MAX_PIPE_NUM];
extern ISP_SNS_COMMBUS_U      g_aunOv2718BusInfo[];

int ov2718_i2c_init(VI_PIPE ViPipe)
{
    char acDevFile[16] = {0};
    GK_U8 u8DevNum;

    if (g_fd[ViPipe] >= 0) {
        return GK_SUCCESS;
    }
#ifdef GPIO_I2C
    int ret;

    g_fd[ViPipe] = open("/dev/gpioi2c_ex", O_RDONLY, S_IRUSR);
    if (g_fd[ViPipe] < 0) {
        ISP_TRACE(MODULE_DBG_ERR, "Open gpioi2c_ex error!\n");
        return GK_FAILURE;
    }
#else
    int ret;

    u8DevNum = g_aunOv2718BusInfo[ViPipe].s8I2cDev;
    snprintf(acDevFile, sizeof(acDevFile),  "/dev/i2c-%u", u8DevNum);

    g_fd[ViPipe] = open(acDevFile, O_RDWR, S_IRUSR | S_IWUSR);

    if (g_fd[ViPipe] < 0) {
        ISP_TRACE(MODULE_DBG_ERR, "Open /dev/i2c_drv-%u error!\n", u8DevNum);
        return GK_FAILURE;
    }

    ret = ioctl(g_fd[ViPipe], I2C_SLAVE_FORCE, (ov2718_i2c_addr >> 1));
    if (ret < 0) {
        ISP_TRACE(MODULE_DBG_ERR, "I2C_SLAVE_FORCE error!\n");
        close(g_fd[ViPipe]);
        g_fd[ViPipe] = -1;
        return ret;
    }
#endif

    return GK_SUCCESS;
}

int ov2718_i2c_exit(VI_PIPE ViPipe)
{
    if (g_fd[ViPipe] >= 0) {
        close(g_fd[ViPipe]);
        g_fd[ViPipe] = -1;
        return GK_SUCCESS;
    }
    return GK_FAILURE;
}

int ov2718_read_register(VI_PIPE ViPipe, int addr)
{
    return GK_SUCCESS;
}


int ov2718_write_register(VI_PIPE ViPipe, GK_U32 addr, GK_U32 data)
{
    if (g_fd[ViPipe] < 0) {
        return GK_SUCCESS;
    }

#ifdef GPIO_I2C
    i2c_data.dev_addr = ov2718_i2c_addr;
    i2c_data.reg_addr = addr;
    i2c_data.addr_byte_num = ov2718_addr_byte;
    i2c_data.data = data;
    i2c_data.data_byte_num = ov2718_data_byte;

    ret = ioctl(g_fd[ViPipe], GPIO_I2C_WRITE, &i2c_data);

    if (ret) {
        ISP_TRACE(MODULE_DBG_ERR, "GPIO-I2C write faild!\n");
        return ret;
    }
#else
    int idx = 0;
    int ret;
    char buf[8];

    if (ov2718_addr_byte == 2) {
        buf[idx] = (addr >> 8) & 0xff;
        idx++;
        buf[idx] = addr & 0xff;
        idx++;
    } else {
    }

    if (ov2718_data_byte == 2) {
    } else {
        buf[idx] = data & 0xff;
        idx++;
    }

    ret = write(g_fd[ViPipe], buf, (ov2718_addr_byte + ov2718_data_byte));
    if (ret < 0) {
        ISP_TRACE(MODULE_DBG_ERR, "I2C_WRITE error!\n");
        return GK_FAILURE;
    }

#endif
    return GK_SUCCESS;
}

static void delay_ms(int ms)
{
    usleep(ms * 1000);
}

void ov2718_standby(VI_PIPE ViPipe)
{
    return;
}

void ov2718_restart(VI_PIPE ViPipe)
{
    return;
}

#define OV2718_SENSOR_1080P_30FPS_LINEAR_MODE   (1)
#define OV2718_SENSOR_1080P_30FPS_WDR_2To1_MODE (2)
#define OV2718_SENSOR_1080P_30FPS_BUILT_IN_MODE (3)

void ov2718_builtin_1080p30_init(VI_PIPE ViPipe);
void ov2718_linear_1080p30_init(VI_PIPE ViPipe);
void ov2718_2wdr1_1080p30_init(VI_PIPE ViPipe);

void ov2718_default_reg_init(VI_PIPE ViPipe)
{
    GK_U32 i;

    for (i = 0; i < g_pastOv2718[ViPipe]->astRegsInfo[0].u32RegNum; i++) {
        ov2718_write_register(ViPipe, g_pastOv2718[ViPipe]->astRegsInfo[0].astI2cData[i].u32RegAddr, g_pastOv2718[ViPipe]->astRegsInfo[0].astI2cData[i].u32Data);
    }
}

void ov2718_init(VI_PIPE ViPipe)
{
    WDR_MODE_E       enWDRMode;
    GK_BOOL          bInit;
    GK_U8            u8ImgMode;

    bInit       = g_pastOv2718[ViPipe]->bInit;
    enWDRMode   = g_pastOv2718[ViPipe]->enWDRMode;
    u8ImgMode   = g_pastOv2718[ViPipe]->u8ImgMode;

    ov2718_i2c_init(ViPipe);

    /* When sensor first init, config all registers */
    if (bInit == GK_FALSE) {
        if (WDR_MODE_2To1_LINE == enWDRMode) {
            if (OV2718_SENSOR_1080P_30FPS_WDR_2To1_MODE == u8ImgMode) { /* SENSOR_1080P_30FPS_MODE */
                ov2718_2wdr1_1080p30_init(ViPipe);
            } else {
                ISP_TRACE(MODULE_DBG_ERR, "Not Support Image Mode %d\n", u8ImgMode);
            }
        } else if (enWDRMode == WDR_MODE_NONE) {
            if (u8ImgMode == OV2718_SENSOR_1080P_30FPS_LINEAR_MODE) { /* SENSOR_1080P_30FPS_MODE */
                ov2718_linear_1080p30_init(ViPipe);
            } else {
                ISP_TRACE(MODULE_DBG_ERR, "Not Support Image Mode %d\n", u8ImgMode);
            }
        } else if (enWDRMode == WDR_MODE_BUILT_IN) {
            if (u8ImgMode == OV2718_SENSOR_1080P_30FPS_BUILT_IN_MODE) {
                ov2718_builtin_1080p30_init(ViPipe);
            } else {
                ISP_TRACE(MODULE_DBG_ERR, "Not Support Sensor Mode %d\n", u8ImgMode);
            }
        }
    }
    /* When sensor switch mode(linear<->WDR or resolution), config different registers(if possible) */
    else {
        if (WDR_MODE_2To1_LINE == enWDRMode) {
            if (OV2718_SENSOR_1080P_30FPS_WDR_2To1_MODE == u8ImgMode) { /* SENSOR_1080P_30FPS_MODE */
                ov2718_2wdr1_1080p30_init(ViPipe);
            } else {
                ISP_TRACE(MODULE_DBG_ERR, "Not Support Image Mode %d\n", u8ImgMode);
            }
        } else if (enWDRMode == WDR_MODE_NONE) {
            if (u8ImgMode == OV2718_SENSOR_1080P_30FPS_LINEAR_MODE) {     /* SENSOR_1080P_30FPS_MODE */
                ov2718_linear_1080p30_init(ViPipe);
            } else {
                ISP_TRACE(MODULE_DBG_ERR, "Not Support Image Mode %d\n", u8ImgMode);
            }
        } else if (enWDRMode == WDR_MODE_BUILT_IN) {
            if (u8ImgMode == OV2718_SENSOR_1080P_30FPS_BUILT_IN_MODE) {
                ov2718_builtin_1080p30_init(ViPipe);
            } else {
                ISP_TRACE(MODULE_DBG_ERR, "Not Support Sensor Mode %d\n", u8ImgMode);
            }
        } else {
            ISP_TRACE(MODULE_DBG_ERR, "Not Support Sensor Mode %d\n", enWDRMode);
        }
    }

    g_pastOv2718[ViPipe]->bInit = GK_TRUE;

    return;
}

void ov2718_exit(VI_PIPE ViPipe)
{
    ov2718_i2c_exit(ViPipe);

    return;
}

/* linear 1080P30 */
void ov2718_linear_1080p30_init(VI_PIPE ViPipe)
{
    delay_ms(5);
    ov2718_write_register(ViPipe, 0x3013, 0x01);
    delay_ms(5);
    ov2718_write_register(ViPipe, 0x3000, 0x05);
    ov2718_write_register(ViPipe, 0x3001, 0x64);
    ov2718_write_register(ViPipe, 0x3002, 0x07);
    ov2718_write_register(ViPipe, 0x3003, 0x01);
    ov2718_write_register(ViPipe, 0x3004, 0x06);
    ov2718_write_register(ViPipe, 0x3005, 0x49);
    ov2718_write_register(ViPipe, 0x3006, 0x00);
    ov2718_write_register(ViPipe, 0x3007, 0x07);
    ov2718_write_register(ViPipe, 0x3008, 0x01);
    ov2718_write_register(ViPipe, 0x3009, 0x00);
    ov2718_write_register(ViPipe, 0x300c, 0x6c);
    ov2718_write_register(ViPipe, 0x300d, 0xe1);
    ov2718_write_register(ViPipe, 0x300e, 0x80);
    ov2718_write_register(ViPipe, 0x300f, 0x00);
    ov2718_write_register(ViPipe, 0x3012, 0x00);
    ov2718_write_register(ViPipe, 0x3013, 0x00);
    ov2718_write_register(ViPipe, 0x3014, 0x04);
    ov2718_write_register(ViPipe, 0x3015, 0x00);
    ov2718_write_register(ViPipe, 0x3017, 0x00);
    ov2718_write_register(ViPipe, 0x3018, 0x00);
    ov2718_write_register(ViPipe, 0x3019, 0x00);
    ov2718_write_register(ViPipe, 0x301a, 0x00);
    ov2718_write_register(ViPipe, 0x301b, 0x01);
    ov2718_write_register(ViPipe, 0x301e, 0x10);
    ov2718_write_register(ViPipe, 0x301f, 0x5f);
    ov2718_write_register(ViPipe, 0x3030, 0x02);
    ov2718_write_register(ViPipe, 0x3031, 0x62);
    ov2718_write_register(ViPipe, 0x3032, 0xf0);
    ov2718_write_register(ViPipe, 0x3033, 0x30);
    ov2718_write_register(ViPipe, 0x3034, 0x34);
    ov2718_write_register(ViPipe, 0x3035, 0x51);
    ov2718_write_register(ViPipe, 0x3036, 0x02);
    ov2718_write_register(ViPipe, 0x3037, 0x9f);
    ov2718_write_register(ViPipe, 0x3038, 0x04);
    ov2718_write_register(ViPipe, 0x3039, 0xb7);
    ov2718_write_register(ViPipe, 0x303a, 0x04);
    ov2718_write_register(ViPipe, 0x303b, 0x07);
    ov2718_write_register(ViPipe, 0x303c, 0xf0);
    ov2718_write_register(ViPipe, 0x303d, 0x00);
    ov2718_write_register(ViPipe, 0x303e, 0x0b);
    ov2718_write_register(ViPipe, 0x303f, 0xe3);
    ov2718_write_register(ViPipe, 0x3040, 0xf3);
    ov2718_write_register(ViPipe, 0x3041, 0x29);
    ov2718_write_register(ViPipe, 0x3042, 0xf6);
    ov2718_write_register(ViPipe, 0x3043, 0x65);
    ov2718_write_register(ViPipe, 0x3044, 0x06);
    ov2718_write_register(ViPipe, 0x3045, 0x0f);
    ov2718_write_register(ViPipe, 0x3046, 0x55);
    ov2718_write_register(ViPipe, 0x3047, 0xf7);
    ov2718_write_register(ViPipe, 0x3048, 0x31);
    ov2718_write_register(ViPipe, 0x3049, 0x0f);
    ov2718_write_register(ViPipe, 0x304a, 0x10);
    ov2718_write_register(ViPipe, 0x304b, 0x40);
    ov2718_write_register(ViPipe, 0x304c, 0x33);
    ov2718_write_register(ViPipe, 0x304d, 0xa4);
    ov2718_write_register(ViPipe, 0x304e, 0x0b);
    ov2718_write_register(ViPipe, 0x304f, 0x3d);
    ov2718_write_register(ViPipe, 0x3050, 0x10);
    ov2718_write_register(ViPipe, 0x3060, 0x00);
    ov2718_write_register(ViPipe, 0x3061, 0x64);
    ov2718_write_register(ViPipe, 0x3062, 0x00);
    ov2718_write_register(ViPipe, 0x3063, 0xe4);
    ov2718_write_register(ViPipe, 0x3064, 0x0b);
    ov2718_write_register(ViPipe, 0x3065, 0x60);
    ov2718_write_register(ViPipe, 0x3066, 0x80);
    ov2718_write_register(ViPipe, 0x3080, 0x00);
    ov2718_write_register(ViPipe, 0x3081, 0x00);
    ov2718_write_register(ViPipe, 0x3082, 0x01);
    ov2718_write_register(ViPipe, 0x3083, 0xe3);
    ov2718_write_register(ViPipe, 0x3084, 0x06);
    ov2718_write_register(ViPipe, 0x3085, 0x00);
    ov2718_write_register(ViPipe, 0x3086, 0x10);
    ov2718_write_register(ViPipe, 0x3087, 0x10);
    ov2718_write_register(ViPipe, 0x3089, 0x00);
    ov2718_write_register(ViPipe, 0x308a, 0x01);
    ov2718_write_register(ViPipe, 0x3093, 0x00);
    ov2718_write_register(ViPipe, 0x30a0, 0x00);
    ov2718_write_register(ViPipe, 0x30a1, 0x04);
    ov2718_write_register(ViPipe, 0x30a2, 0x00);
    ov2718_write_register(ViPipe, 0x30a3, 0x04);
    ov2718_write_register(ViPipe, 0x30a4, 0x07);
    ov2718_write_register(ViPipe, 0x30a5, 0x8b);
    ov2718_write_register(ViPipe, 0x30a6, 0x04);
    ov2718_write_register(ViPipe, 0x30a7, 0x43);
    ov2718_write_register(ViPipe, 0x30a8, 0x00);
    ov2718_write_register(ViPipe, 0x30a9, 0x00);
    ov2718_write_register(ViPipe, 0x30aa, 0x00);
    ov2718_write_register(ViPipe, 0x30ab, 0x04);
    ov2718_write_register(ViPipe, 0x30ac, 0x07);
    ov2718_write_register(ViPipe, 0x30ad, 0x80);
    ov2718_write_register(ViPipe, 0x30ae, 0x04);
    ov2718_write_register(ViPipe, 0x30af, 0x38);
    ov2718_write_register(ViPipe, 0x30b0, 0x08);
    ov2718_write_register(ViPipe, 0x30b1, 0x98);
    ov2718_write_register(ViPipe, 0x30b2, 0x04);
    ov2718_write_register(ViPipe, 0x30b3, 0x65);
    ov2718_write_register(ViPipe, 0x30b4, 0x00);
    ov2718_write_register(ViPipe, 0x30b5, 0x00);
    ov2718_write_register(ViPipe, 0x30b6, 0x00);
    ov2718_write_register(ViPipe, 0x30b7, 0x10);
    ov2718_write_register(ViPipe, 0x30b8, 0x00);
    ov2718_write_register(ViPipe, 0x30b9, 0x02);
    ov2718_write_register(ViPipe, 0x30ba, 0x10);
    ov2718_write_register(ViPipe, 0x30bb, 0x00);
    ov2718_write_register(ViPipe, 0x30bc, 0x00);
    ov2718_write_register(ViPipe, 0x30bd, 0x03);
    ov2718_write_register(ViPipe, 0x30be, 0x5c);
    ov2718_write_register(ViPipe, 0x30bf, 0x00);
    ov2718_write_register(ViPipe, 0x30c0, 0x08);
    ov2718_write_register(ViPipe, 0x30c1, 0x00);
    ov2718_write_register(ViPipe, 0x30c2, 0x20);
    ov2718_write_register(ViPipe, 0x30c3, 0x00);
    ov2718_write_register(ViPipe, 0x30c4, 0x4a);
    ov2718_write_register(ViPipe, 0x30c5, 0x00);
    ov2718_write_register(ViPipe, 0x30c7, 0x00);
    ov2718_write_register(ViPipe, 0x30c8, 0x00);
    ov2718_write_register(ViPipe, 0x30d1, 0x00);
    ov2718_write_register(ViPipe, 0x30d2, 0x00);
    ov2718_write_register(ViPipe, 0x30d3, 0x80);
    ov2718_write_register(ViPipe, 0x30d4, 0x00);
    ov2718_write_register(ViPipe, 0x30d9, 0x09);
    ov2718_write_register(ViPipe, 0x30da, 0x64);
    ov2718_write_register(ViPipe, 0x30dd, 0x00);
    ov2718_write_register(ViPipe, 0x30de, 0x16);
    ov2718_write_register(ViPipe, 0x30df, 0x00);
    ov2718_write_register(ViPipe, 0x30e0, 0x17);
    ov2718_write_register(ViPipe, 0x30e1, 0x00);
    ov2718_write_register(ViPipe, 0x30e2, 0x18);
    ov2718_write_register(ViPipe, 0x30e3, 0x10);
    ov2718_write_register(ViPipe, 0x30e4, 0x04);
    ov2718_write_register(ViPipe, 0x30e5, 0x00);
    ov2718_write_register(ViPipe, 0x30e6, 0x00);
    ov2718_write_register(ViPipe, 0x30e7, 0x00);
    ov2718_write_register(ViPipe, 0x30e8, 0x00);
    ov2718_write_register(ViPipe, 0x30e9, 0x00);
    ov2718_write_register(ViPipe, 0x30ea, 0x00);
    ov2718_write_register(ViPipe, 0x30eb, 0x00);
    ov2718_write_register(ViPipe, 0x30ec, 0x00);
    ov2718_write_register(ViPipe, 0x30ed, 0x00);
    ov2718_write_register(ViPipe, 0x3101, 0x00);
    ov2718_write_register(ViPipe, 0x3102, 0x00);
    ov2718_write_register(ViPipe, 0x3103, 0x00);
    ov2718_write_register(ViPipe, 0x3104, 0x00);
    ov2718_write_register(ViPipe, 0x3105, 0x79);
    ov2718_write_register(ViPipe, 0x3106, 0x81);
    ov2718_write_register(ViPipe, 0x3107, 0x75);
    ov2718_write_register(ViPipe, 0x3108, 0x80);
    ov2718_write_register(ViPipe, 0x3109, 0x6c);
    ov2718_write_register(ViPipe, 0x310a, 0x83);
    ov2718_write_register(ViPipe, 0x310b, 0x69);
    ov2718_write_register(ViPipe, 0x310c, 0x43);
    ov2718_write_register(ViPipe, 0x310d, 0x42);
    ov2718_write_register(ViPipe, 0x310e, 0x00);
    ov2718_write_register(ViPipe, 0x3120, 0x00);
    ov2718_write_register(ViPipe, 0x3121, 0x00);
    ov2718_write_register(ViPipe, 0x3122, 0x00);
    ov2718_write_register(ViPipe, 0x3123, 0xf0);
    ov2718_write_register(ViPipe, 0x3124, 0x00);
    ov2718_write_register(ViPipe, 0x3125, 0xa0);
    ov2718_write_register(ViPipe, 0x3126, 0x3f);
    ov2718_write_register(ViPipe, 0x3127, 0x0f);
    ov2718_write_register(ViPipe, 0x3128, 0x00);
    ov2718_write_register(ViPipe, 0x3129, 0x3a);
    ov2718_write_register(ViPipe, 0x312a, 0x02);
    ov2718_write_register(ViPipe, 0x312b, 0x0f);
    ov2718_write_register(ViPipe, 0x312c, 0x00);
    ov2718_write_register(ViPipe, 0x312d, 0x0f);
    ov2718_write_register(ViPipe, 0x312e, 0x1d);
    ov2718_write_register(ViPipe, 0x312f, 0x00);
    ov2718_write_register(ViPipe, 0x3130, 0x00);
    ov2718_write_register(ViPipe, 0x3131, 0x00);
    ov2718_write_register(ViPipe, 0x3132, 0x00);
    ov2718_write_register(ViPipe, 0x3140, 0x02);
    ov2718_write_register(ViPipe, 0x3141, 0x03);
    ov2718_write_register(ViPipe, 0x3142, 0x00);
    ov2718_write_register(ViPipe, 0x3143, 0x00);
    ov2718_write_register(ViPipe, 0x3144, 0x00);
    ov2718_write_register(ViPipe, 0x3145, 0x00);
    ov2718_write_register(ViPipe, 0x3146, 0x00);
    ov2718_write_register(ViPipe, 0x3147, 0x00);
    ov2718_write_register(ViPipe, 0x3148, 0x00);
    ov2718_write_register(ViPipe, 0x3149, 0x00);
    ov2718_write_register(ViPipe, 0x314a, 0x00);
    ov2718_write_register(ViPipe, 0x314b, 0x00);
    ov2718_write_register(ViPipe, 0x314c, 0x00);
    ov2718_write_register(ViPipe, 0x314d, 0x00);
    ov2718_write_register(ViPipe, 0x314e, 0x1c);
    ov2718_write_register(ViPipe, 0x314f, 0x02);
    ov2718_write_register(ViPipe, 0x3150, 0x02);
    ov2718_write_register(ViPipe, 0x3151, 0x02);
    ov2718_write_register(ViPipe, 0x3152, 0x10);
    ov2718_write_register(ViPipe, 0x3153, 0x10);
    ov2718_write_register(ViPipe, 0x3154, 0x10);
    ov2718_write_register(ViPipe, 0x3155, 0x00);
    ov2718_write_register(ViPipe, 0x3156, 0x03);
    ov2718_write_register(ViPipe, 0x3157, 0x00);
    ov2718_write_register(ViPipe, 0x3158, 0x0f);
    ov2718_write_register(ViPipe, 0x3159, 0xff);
    ov2718_write_register(ViPipe, 0x315a, 0x01);
    ov2718_write_register(ViPipe, 0x315b, 0x00);
    ov2718_write_register(ViPipe, 0x315c, 0x01);
    ov2718_write_register(ViPipe, 0x315d, 0x00);
    ov2718_write_register(ViPipe, 0x315e, 0x01);
    ov2718_write_register(ViPipe, 0x315f, 0x00);
    ov2718_write_register(ViPipe, 0x3160, 0x00);
    ov2718_write_register(ViPipe, 0x3161, 0x40);
    ov2718_write_register(ViPipe, 0x3162, 0x00);
    ov2718_write_register(ViPipe, 0x3163, 0x40);
    ov2718_write_register(ViPipe, 0x3164, 0x00);
    ov2718_write_register(ViPipe, 0x3165, 0x40);
    ov2718_write_register(ViPipe, 0x3190, 0x08);
    ov2718_write_register(ViPipe, 0x3191, 0x99);
    ov2718_write_register(ViPipe, 0x3193, 0x08);
    ov2718_write_register(ViPipe, 0x3194, 0x13);
    ov2718_write_register(ViPipe, 0x3195, 0x33);
    ov2718_write_register(ViPipe, 0x3196, 0x00);
    ov2718_write_register(ViPipe, 0x3197, 0x10);
    ov2718_write_register(ViPipe, 0x3198, 0x00);
    ov2718_write_register(ViPipe, 0x3199, 0x7f);
    ov2718_write_register(ViPipe, 0x319a, 0x80);
    ov2718_write_register(ViPipe, 0x319b, 0xff);
    ov2718_write_register(ViPipe, 0x319c, 0x80);
    ov2718_write_register(ViPipe, 0x319d, 0xbf);
    ov2718_write_register(ViPipe, 0x319e, 0xc0);
    ov2718_write_register(ViPipe, 0x319f, 0xff);
    ov2718_write_register(ViPipe, 0x31a0, 0x24);
    ov2718_write_register(ViPipe, 0x31a1, 0x55);
    ov2718_write_register(ViPipe, 0x31a2, 0x00);
    ov2718_write_register(ViPipe, 0x31a3, 0x00);
    ov2718_write_register(ViPipe, 0x31a6, 0x00);
    ov2718_write_register(ViPipe, 0x31a7, 0x00);
    ov2718_write_register(ViPipe, 0x31b0, 0x00);
    ov2718_write_register(ViPipe, 0x31b1, 0x00);
    ov2718_write_register(ViPipe, 0x31b2, 0x02);
    ov2718_write_register(ViPipe, 0x31b3, 0x00);
    ov2718_write_register(ViPipe, 0x31b4, 0x00);
    ov2718_write_register(ViPipe, 0x31b5, 0x01);
    ov2718_write_register(ViPipe, 0x31b6, 0x00);
    ov2718_write_register(ViPipe, 0x31b7, 0x00);
    ov2718_write_register(ViPipe, 0x31b8, 0x00);
    ov2718_write_register(ViPipe, 0x31b9, 0x00);
    ov2718_write_register(ViPipe, 0x31ba, 0x00);
    ov2718_write_register(ViPipe, 0x31d0, 0x3c);
    ov2718_write_register(ViPipe, 0x31d1, 0x34);
    ov2718_write_register(ViPipe, 0x31d2, 0x3c);
    ov2718_write_register(ViPipe, 0x31d3, 0x00);
    ov2718_write_register(ViPipe, 0x31d4, 0x2d);
    ov2718_write_register(ViPipe, 0x31d5, 0x00);
    ov2718_write_register(ViPipe, 0x31d6, 0x01);
    ov2718_write_register(ViPipe, 0x31d7, 0x06);
    ov2718_write_register(ViPipe, 0x31d8, 0x00);
    ov2718_write_register(ViPipe, 0x31d9, 0x64);
    ov2718_write_register(ViPipe, 0x31da, 0x00);
    ov2718_write_register(ViPipe, 0x31db, 0x28);
    ov2718_write_register(ViPipe, 0x31dc, 0x04);
    ov2718_write_register(ViPipe, 0x31dd, 0x69);
    ov2718_write_register(ViPipe, 0x31de, 0x0a);
    ov2718_write_register(ViPipe, 0x31df, 0x3c);
    ov2718_write_register(ViPipe, 0x31e0, 0x04);
    ov2718_write_register(ViPipe, 0x31e1, 0x32);
    ov2718_write_register(ViPipe, 0x31e2, 0x00);
    ov2718_write_register(ViPipe, 0x31e3, 0x01);
    ov2718_write_register(ViPipe, 0x31e4, 0x0d);
    ov2718_write_register(ViPipe, 0x31e5, 0x80);
    ov2718_write_register(ViPipe, 0x31e6, 0x00);
    ov2718_write_register(ViPipe, 0x31e7, 0x2c);
    ov2718_write_register(ViPipe, 0x31e8, 0x6c);
    ov2718_write_register(ViPipe, 0x31e9, 0xac);
    ov2718_write_register(ViPipe, 0x31ea, 0xec);
    ov2718_write_register(ViPipe, 0x31eb, 0x3f);
    ov2718_write_register(ViPipe, 0x31ec, 0x0f);
    ov2718_write_register(ViPipe, 0x31ed, 0x20);
    ov2718_write_register(ViPipe, 0x31ee, 0x04);
    ov2718_write_register(ViPipe, 0x31ef, 0x48);
    ov2718_write_register(ViPipe, 0x31f0, 0x07);
    ov2718_write_register(ViPipe, 0x31f1, 0x90);
    ov2718_write_register(ViPipe, 0x31f2, 0x04);
    ov2718_write_register(ViPipe, 0x31f3, 0x48);
    ov2718_write_register(ViPipe, 0x31f4, 0x07);
    ov2718_write_register(ViPipe, 0x31f5, 0x90);
    ov2718_write_register(ViPipe, 0x31f6, 0x04);
    ov2718_write_register(ViPipe, 0x31f7, 0x48);
    ov2718_write_register(ViPipe, 0x31f8, 0x07);
    ov2718_write_register(ViPipe, 0x31f9, 0x90);
    ov2718_write_register(ViPipe, 0x31fa, 0x04);
    ov2718_write_register(ViPipe, 0x31fb, 0x48);
    ov2718_write_register(ViPipe, 0x31fd, 0xcb);
    ov2718_write_register(ViPipe, 0x31fe, 0x0f);
    ov2718_write_register(ViPipe, 0x31ff, 0x03);
    ov2718_write_register(ViPipe, 0x3200, 0x00);
    ov2718_write_register(ViPipe, 0x3201, 0xff);
    ov2718_write_register(ViPipe, 0x3202, 0x00);
    ov2718_write_register(ViPipe, 0x3203, 0xff);
    ov2718_write_register(ViPipe, 0x3204, 0xff);
    ov2718_write_register(ViPipe, 0x3205, 0xff);
    ov2718_write_register(ViPipe, 0x3206, 0xff);
    ov2718_write_register(ViPipe, 0x3207, 0xff);
    ov2718_write_register(ViPipe, 0x3208, 0xff);
    ov2718_write_register(ViPipe, 0x3209, 0xff);
    ov2718_write_register(ViPipe, 0x320a, 0xff);
    ov2718_write_register(ViPipe, 0x320b, 0x1b);
    ov2718_write_register(ViPipe, 0x320c, 0x1f);
    ov2718_write_register(ViPipe, 0x320d, 0x1e);
    ov2718_write_register(ViPipe, 0x320e, 0x30);
    ov2718_write_register(ViPipe, 0x320f, 0x2d);
    ov2718_write_register(ViPipe, 0x3210, 0x2c);
    ov2718_write_register(ViPipe, 0x3211, 0x2b);
    ov2718_write_register(ViPipe, 0x3212, 0x2a);
    ov2718_write_register(ViPipe, 0x3213, 0x24);
    ov2718_write_register(ViPipe, 0x3214, 0x22);
    ov2718_write_register(ViPipe, 0x3215, 0x00);
    ov2718_write_register(ViPipe, 0x3216, 0x04);
    ov2718_write_register(ViPipe, 0x3217, 0x2c);
    ov2718_write_register(ViPipe, 0x3218, 0x6c);
    ov2718_write_register(ViPipe, 0x3219, 0xac);
    ov2718_write_register(ViPipe, 0x321a, 0xec);
    ov2718_write_register(ViPipe, 0x321b, 0x00);
    ov2718_write_register(ViPipe, 0x3230, 0x3a);
    ov2718_write_register(ViPipe, 0x3231, 0x00);
    ov2718_write_register(ViPipe, 0x3232, 0x80);
    ov2718_write_register(ViPipe, 0x3233, 0x00);
    ov2718_write_register(ViPipe, 0x3234, 0x10);
    ov2718_write_register(ViPipe, 0x3235, 0xaa);
    ov2718_write_register(ViPipe, 0x3236, 0x55);
    ov2718_write_register(ViPipe, 0x3237, 0x99);
    ov2718_write_register(ViPipe, 0x3238, 0x66);
    ov2718_write_register(ViPipe, 0x3239, 0x08);
    ov2718_write_register(ViPipe, 0x323a, 0x88);
    ov2718_write_register(ViPipe, 0x323b, 0x00);
    ov2718_write_register(ViPipe, 0x323c, 0x00);
    ov2718_write_register(ViPipe, 0x323d, 0x03);
    ov2718_write_register(ViPipe, 0x3250, 0x33);
    ov2718_write_register(ViPipe, 0x3251, 0x00);
    ov2718_write_register(ViPipe, 0x3252, 0x22);
    ov2718_write_register(ViPipe, 0x3253, 0x00);
    ov2718_write_register(ViPipe, 0x3254, 0x00);
    ov2718_write_register(ViPipe, 0x3255, 0x01);
    ov2718_write_register(ViPipe, 0x3256, 0x00);
    ov2718_write_register(ViPipe, 0x3257, 0x00);
    ov2718_write_register(ViPipe, 0x3258, 0x00);
    ov2718_write_register(ViPipe, 0x3270, 0x01);
    ov2718_write_register(ViPipe, 0x3271, 0x60);
    ov2718_write_register(ViPipe, 0x3272, 0xc0);
    ov2718_write_register(ViPipe, 0x3273, 0x00);
    ov2718_write_register(ViPipe, 0x3274, 0x80);
    ov2718_write_register(ViPipe, 0x3275, 0x40);
    ov2718_write_register(ViPipe, 0x3276, 0x02);
    ov2718_write_register(ViPipe, 0x3277, 0x08);
    ov2718_write_register(ViPipe, 0x3278, 0x10);
    ov2718_write_register(ViPipe, 0x3279, 0x04);
    ov2718_write_register(ViPipe, 0x327a, 0x00);
    ov2718_write_register(ViPipe, 0x327b, 0x03);
    ov2718_write_register(ViPipe, 0x327c, 0x10);
    ov2718_write_register(ViPipe, 0x327d, 0x60);
    ov2718_write_register(ViPipe, 0x327e, 0xc0);
    ov2718_write_register(ViPipe, 0x327f, 0x06);
    ov2718_write_register(ViPipe, 0x3288, 0x10);
    ov2718_write_register(ViPipe, 0x3289, 0x00);
    ov2718_write_register(ViPipe, 0x328a, 0x08);
    ov2718_write_register(ViPipe, 0x328b, 0x00);
    ov2718_write_register(ViPipe, 0x328c, 0x04);
    ov2718_write_register(ViPipe, 0x328d, 0x00);
    ov2718_write_register(ViPipe, 0x328e, 0x02);
    ov2718_write_register(ViPipe, 0x328f, 0x00);
    ov2718_write_register(ViPipe, 0x3290, 0x20);
    ov2718_write_register(ViPipe, 0x3291, 0x00);
    ov2718_write_register(ViPipe, 0x3292, 0x10);
    ov2718_write_register(ViPipe, 0x3293, 0x00);
    ov2718_write_register(ViPipe, 0x3294, 0x08);
    ov2718_write_register(ViPipe, 0x3295, 0x00);
    ov2718_write_register(ViPipe, 0x3296, 0x04);
    ov2718_write_register(ViPipe, 0x3297, 0x00);
    ov2718_write_register(ViPipe, 0x3298, 0x40);
    ov2718_write_register(ViPipe, 0x3299, 0x00);
    ov2718_write_register(ViPipe, 0x329a, 0x20);
    ov2718_write_register(ViPipe, 0x329b, 0x00);
    ov2718_write_register(ViPipe, 0x329c, 0x10);
    ov2718_write_register(ViPipe, 0x329d, 0x00);
    ov2718_write_register(ViPipe, 0x329e, 0x08);
    ov2718_write_register(ViPipe, 0x329f, 0x00);
    ov2718_write_register(ViPipe, 0x32a0, 0x7f);
    ov2718_write_register(ViPipe, 0x32a1, 0xff);
    ov2718_write_register(ViPipe, 0x32a2, 0x40);
    ov2718_write_register(ViPipe, 0x32a3, 0x00);
    ov2718_write_register(ViPipe, 0x32a4, 0x20);
    ov2718_write_register(ViPipe, 0x32a5, 0x00);
    ov2718_write_register(ViPipe, 0x32a6, 0x10);
    ov2718_write_register(ViPipe, 0x32a7, 0x00);
    ov2718_write_register(ViPipe, 0x32a8, 0x00);
    ov2718_write_register(ViPipe, 0x32a9, 0x00);
    ov2718_write_register(ViPipe, 0x32aa, 0x00);
    ov2718_write_register(ViPipe, 0x32ab, 0x00);
    ov2718_write_register(ViPipe, 0x32ac, 0x00);
    ov2718_write_register(ViPipe, 0x32ad, 0x00);
    ov2718_write_register(ViPipe, 0x32ae, 0x00);
    ov2718_write_register(ViPipe, 0x32af, 0x00);
    ov2718_write_register(ViPipe, 0x32b0, 0x00);
    ov2718_write_register(ViPipe, 0x32b1, 0x00);
    ov2718_write_register(ViPipe, 0x32b2, 0x00);
    ov2718_write_register(ViPipe, 0x32b3, 0x00);
    ov2718_write_register(ViPipe, 0x32b4, 0x00);
    ov2718_write_register(ViPipe, 0x32b5, 0x00);
    ov2718_write_register(ViPipe, 0x32b6, 0x00);
    ov2718_write_register(ViPipe, 0x32b7, 0x00);
    ov2718_write_register(ViPipe, 0x32b8, 0x00);
    ov2718_write_register(ViPipe, 0x32b9, 0x00);
    ov2718_write_register(ViPipe, 0x32ba, 0x00);
    ov2718_write_register(ViPipe, 0x32bb, 0x00);
    ov2718_write_register(ViPipe, 0x32bc, 0x00);
    ov2718_write_register(ViPipe, 0x32bd, 0x00);
    ov2718_write_register(ViPipe, 0x32be, 0x00);
    ov2718_write_register(ViPipe, 0x32bf, 0x00);
    ov2718_write_register(ViPipe, 0x32c0, 0x00);
    ov2718_write_register(ViPipe, 0x32c1, 0x00);
    ov2718_write_register(ViPipe, 0x32c2, 0x00);
    ov2718_write_register(ViPipe, 0x32c3, 0x00);
    ov2718_write_register(ViPipe, 0x32c4, 0x00);
    ov2718_write_register(ViPipe, 0x32c5, 0x00);
    ov2718_write_register(ViPipe, 0x32c6, 0x00);
    ov2718_write_register(ViPipe, 0x32c7, 0x00);
    ov2718_write_register(ViPipe, 0x32c8, 0x87);
    ov2718_write_register(ViPipe, 0x32c9, 0x00);
    ov2718_write_register(ViPipe, 0x3330, 0x03);
    ov2718_write_register(ViPipe, 0x3331, 0xc8);
    ov2718_write_register(ViPipe, 0x3332, 0x02);
    ov2718_write_register(ViPipe, 0x3333, 0x24);
    ov2718_write_register(ViPipe, 0x3334, 0x00);
    ov2718_write_register(ViPipe, 0x3335, 0x00);
    ov2718_write_register(ViPipe, 0x3336, 0x00);
    ov2718_write_register(ViPipe, 0x3337, 0x00);
    ov2718_write_register(ViPipe, 0x3338, 0x03);
    ov2718_write_register(ViPipe, 0x3339, 0xc8);
    ov2718_write_register(ViPipe, 0x333a, 0x02);
    ov2718_write_register(ViPipe, 0x333b, 0x24);
    ov2718_write_register(ViPipe, 0x333c, 0x00);
    ov2718_write_register(ViPipe, 0x333d, 0x00);
    ov2718_write_register(ViPipe, 0x333e, 0x00);
    ov2718_write_register(ViPipe, 0x333f, 0x00);
    ov2718_write_register(ViPipe, 0x3340, 0x03);
    ov2718_write_register(ViPipe, 0x3341, 0xc8);
    ov2718_write_register(ViPipe, 0x3342, 0x02);
    ov2718_write_register(ViPipe, 0x3343, 0x24);
    ov2718_write_register(ViPipe, 0x3344, 0x00);
    ov2718_write_register(ViPipe, 0x3345, 0x00);
    ov2718_write_register(ViPipe, 0x3346, 0x00);
    ov2718_write_register(ViPipe, 0x3347, 0x00);
    ov2718_write_register(ViPipe, 0x3348, 0x40);
    ov2718_write_register(ViPipe, 0x3349, 0x00);
    ov2718_write_register(ViPipe, 0x334a, 0x00);
    ov2718_write_register(ViPipe, 0x334b, 0x00);
    ov2718_write_register(ViPipe, 0x334c, 0x00);
    ov2718_write_register(ViPipe, 0x334d, 0x00);
    ov2718_write_register(ViPipe, 0x334e, 0x80);
    ov2718_write_register(ViPipe, 0x3360, 0x01);
    ov2718_write_register(ViPipe, 0x3361, 0x00);
    ov2718_write_register(ViPipe, 0x3362, 0x01);
    ov2718_write_register(ViPipe, 0x3363, 0x00);
    ov2718_write_register(ViPipe, 0x3364, 0x01);
    ov2718_write_register(ViPipe, 0x3365, 0x00);
    ov2718_write_register(ViPipe, 0x3366, 0x01);
    ov2718_write_register(ViPipe, 0x3367, 0x00);
    ov2718_write_register(ViPipe, 0x3368, 0x01);
    ov2718_write_register(ViPipe, 0x3369, 0x00);
    ov2718_write_register(ViPipe, 0x336a, 0x01);
    ov2718_write_register(ViPipe, 0x336b, 0x00);
    ov2718_write_register(ViPipe, 0x336c, 0x01);
    ov2718_write_register(ViPipe, 0x336d, 0x00);
    ov2718_write_register(ViPipe, 0x336e, 0x01);
    ov2718_write_register(ViPipe, 0x336f, 0x00);
    ov2718_write_register(ViPipe, 0x3370, 0x01);
    ov2718_write_register(ViPipe, 0x3371, 0x00);
    ov2718_write_register(ViPipe, 0x3372, 0x01);
    ov2718_write_register(ViPipe, 0x3373, 0x00);
    ov2718_write_register(ViPipe, 0x3374, 0x01);
    ov2718_write_register(ViPipe, 0x3375, 0x00);
    ov2718_write_register(ViPipe, 0x3376, 0x01);
    ov2718_write_register(ViPipe, 0x3377, 0x00);
    ov2718_write_register(ViPipe, 0x3378, 0x00);
    ov2718_write_register(ViPipe, 0x3379, 0x00);
    ov2718_write_register(ViPipe, 0x337a, 0x00);
    ov2718_write_register(ViPipe, 0x337b, 0x00);
    ov2718_write_register(ViPipe, 0x337c, 0x00);
    ov2718_write_register(ViPipe, 0x337d, 0x00);
    ov2718_write_register(ViPipe, 0x337e, 0x00);
    ov2718_write_register(ViPipe, 0x337f, 0x00);
    ov2718_write_register(ViPipe, 0x3380, 0x00);
    ov2718_write_register(ViPipe, 0x3381, 0x00);
    ov2718_write_register(ViPipe, 0x3382, 0x00);
    ov2718_write_register(ViPipe, 0x3383, 0x00);
    ov2718_write_register(ViPipe, 0x3384, 0x00);
    ov2718_write_register(ViPipe, 0x3385, 0x00);
    ov2718_write_register(ViPipe, 0x3386, 0x00);
    ov2718_write_register(ViPipe, 0x3387, 0x00);
    ov2718_write_register(ViPipe, 0x3388, 0x00);
    ov2718_write_register(ViPipe, 0x3389, 0x00);
    ov2718_write_register(ViPipe, 0x338a, 0x00);
    ov2718_write_register(ViPipe, 0x338b, 0x00);
    ov2718_write_register(ViPipe, 0x338c, 0x00);
    ov2718_write_register(ViPipe, 0x338d, 0x00);
    ov2718_write_register(ViPipe, 0x338e, 0x00);
    ov2718_write_register(ViPipe, 0x338f, 0x00);
    ov2718_write_register(ViPipe, 0x3390, 0x00);
    ov2718_write_register(ViPipe, 0x3391, 0x00);
    ov2718_write_register(ViPipe, 0x3392, 0x00);
    ov2718_write_register(ViPipe, 0x3393, 0x00);
    ov2718_write_register(ViPipe, 0x3394, 0x00);
    ov2718_write_register(ViPipe, 0x3395, 0x00);
    ov2718_write_register(ViPipe, 0x3396, 0x00);
    ov2718_write_register(ViPipe, 0x3397, 0x00);
    ov2718_write_register(ViPipe, 0x3398, 0x00);
    ov2718_write_register(ViPipe, 0x3399, 0x00);
    ov2718_write_register(ViPipe, 0x339a, 0x00);
    ov2718_write_register(ViPipe, 0x339b, 0x00);
    ov2718_write_register(ViPipe, 0x33b0, 0x00);
    ov2718_write_register(ViPipe, 0x33b1, 0x50);
    ov2718_write_register(ViPipe, 0x33b2, 0x01);
    ov2718_write_register(ViPipe, 0x33b3, 0xff);
    ov2718_write_register(ViPipe, 0x33b4, 0xe0);
    ov2718_write_register(ViPipe, 0x33b5, 0x6b);
    ov2718_write_register(ViPipe, 0x33b6, 0x00);
    ov2718_write_register(ViPipe, 0x33b7, 0x00);
    ov2718_write_register(ViPipe, 0x33b8, 0x00);
    ov2718_write_register(ViPipe, 0x33b9, 0x00);
    ov2718_write_register(ViPipe, 0x33ba, 0x02);
    ov2718_write_register(ViPipe, 0x33bb, 0x08);
    ov2718_write_register(ViPipe, 0x33bc, 0x01);
    ov2718_write_register(ViPipe, 0x33bd, 0x01);
    ov2718_write_register(ViPipe, 0x33be, 0x01);
    ov2718_write_register(ViPipe, 0x33bf, 0x01);
    ov2718_write_register(ViPipe, 0x33c0, 0x00);
    ov2718_write_register(ViPipe, 0x33c1, 0x00);
    ov2718_write_register(ViPipe, 0x33c2, 0x00);
    ov2718_write_register(ViPipe, 0x33c3, 0x00);
    ov2718_write_register(ViPipe, 0x33e0, 0x14);
    ov2718_write_register(ViPipe, 0x33e1, 0x0f);
    ov2718_write_register(ViPipe, 0x33e2, 0x04);
    ov2718_write_register(ViPipe, 0x33e3, 0x02);
    ov2718_write_register(ViPipe, 0x33e4, 0x01);
    ov2718_write_register(ViPipe, 0x33e5, 0x01);
    ov2718_write_register(ViPipe, 0x33e6, 0x00);
    ov2718_write_register(ViPipe, 0x33e7, 0x04);
    ov2718_write_register(ViPipe, 0x33e8, 0x0c);
    ov2718_write_register(ViPipe, 0x33e9, 0x00);
    ov2718_write_register(ViPipe, 0x33ea, 0x01);
    ov2718_write_register(ViPipe, 0x33eb, 0x02);
    ov2718_write_register(ViPipe, 0x33ec, 0x03);
    ov2718_write_register(ViPipe, 0x33ed, 0x02);
    ov2718_write_register(ViPipe, 0x33ee, 0x05);
    ov2718_write_register(ViPipe, 0x33ef, 0x0a);
    ov2718_write_register(ViPipe, 0x33f0, 0x08);
    ov2718_write_register(ViPipe, 0x33f1, 0x04);
    ov2718_write_register(ViPipe, 0x33f2, 0x04);
    ov2718_write_register(ViPipe, 0x33f3, 0x00);
    ov2718_write_register(ViPipe, 0x33f4, 0x03);
    ov2718_write_register(ViPipe, 0x33f5, 0x14);
    ov2718_write_register(ViPipe, 0x33f6, 0x0f);
    ov2718_write_register(ViPipe, 0x33f7, 0x02);
    ov2718_write_register(ViPipe, 0x33f8, 0x01);
    ov2718_write_register(ViPipe, 0x33f9, 0x01);
    ov2718_write_register(ViPipe, 0x33fa, 0x01);
    ov2718_write_register(ViPipe, 0x33fb, 0x00);
    ov2718_write_register(ViPipe, 0x33fc, 0x04);
    ov2718_write_register(ViPipe, 0x33fd, 0x0c);
    ov2718_write_register(ViPipe, 0x33fe, 0x00);
    ov2718_write_register(ViPipe, 0x33ff, 0x01);
    ov2718_write_register(ViPipe, 0x3400, 0x02);
    ov2718_write_register(ViPipe, 0x3401, 0x03);
    ov2718_write_register(ViPipe, 0x3402, 0x01);
    ov2718_write_register(ViPipe, 0x3403, 0x02);
    ov2718_write_register(ViPipe, 0x3404, 0x08);
    ov2718_write_register(ViPipe, 0x3405, 0x08);
    ov2718_write_register(ViPipe, 0x3406, 0x04);
    ov2718_write_register(ViPipe, 0x3407, 0x04);
    ov2718_write_register(ViPipe, 0x3408, 0x00);
    ov2718_write_register(ViPipe, 0x3409, 0x03);
    ov2718_write_register(ViPipe, 0x340a, 0x14);
    ov2718_write_register(ViPipe, 0x340b, 0x0f);
    ov2718_write_register(ViPipe, 0x340c, 0x04);
    ov2718_write_register(ViPipe, 0x340d, 0x02);
    ov2718_write_register(ViPipe, 0x340e, 0x01);
    ov2718_write_register(ViPipe, 0x340f, 0x01);
    ov2718_write_register(ViPipe, 0x3410, 0x00);
    ov2718_write_register(ViPipe, 0x3411, 0x04);
    ov2718_write_register(ViPipe, 0x3412, 0x0c);
    ov2718_write_register(ViPipe, 0x3413, 0x00);
    ov2718_write_register(ViPipe, 0x3414, 0x01);
    ov2718_write_register(ViPipe, 0x3415, 0x02);
    ov2718_write_register(ViPipe, 0x3416, 0x03);
    ov2718_write_register(ViPipe, 0x3417, 0x02);
    ov2718_write_register(ViPipe, 0x3418, 0x05);
    ov2718_write_register(ViPipe, 0x3419, 0x0a);
    ov2718_write_register(ViPipe, 0x341a, 0x08);
    ov2718_write_register(ViPipe, 0x341b, 0x04);
    ov2718_write_register(ViPipe, 0x341c, 0x04);
    ov2718_write_register(ViPipe, 0x341d, 0x00);
    ov2718_write_register(ViPipe, 0x341e, 0x03);
    ov2718_write_register(ViPipe, 0x3440, 0x00);
    ov2718_write_register(ViPipe, 0x3441, 0x00);
    ov2718_write_register(ViPipe, 0x3442, 0x00);
    ov2718_write_register(ViPipe, 0x3443, 0x00);
    ov2718_write_register(ViPipe, 0x3444, 0x02);
    ov2718_write_register(ViPipe, 0x3445, 0xf0);
    ov2718_write_register(ViPipe, 0x3446, 0x02);
    ov2718_write_register(ViPipe, 0x3447, 0x08);
    ov2718_write_register(ViPipe, 0x3448, 0x00);
    ov2718_write_register(ViPipe, 0x3460, 0x40);
    ov2718_write_register(ViPipe, 0x3461, 0x40);
    ov2718_write_register(ViPipe, 0x3462, 0x40);
    ov2718_write_register(ViPipe, 0x3463, 0x40);
    ov2718_write_register(ViPipe, 0x3464, 0x03);
    ov2718_write_register(ViPipe, 0x3465, 0x01);
    ov2718_write_register(ViPipe, 0x3466, 0x01);
    ov2718_write_register(ViPipe, 0x3467, 0x02);
    ov2718_write_register(ViPipe, 0x3468, 0x30);
    ov2718_write_register(ViPipe, 0x3469, 0x00);
    ov2718_write_register(ViPipe, 0x346a, 0x33);
    ov2718_write_register(ViPipe, 0x346b, 0xbf);
    ov2718_write_register(ViPipe, 0x3480, 0x40);
    ov2718_write_register(ViPipe, 0x3481, 0x00);
    ov2718_write_register(ViPipe, 0x3482, 0x00);
    ov2718_write_register(ViPipe, 0x3483, 0x00);
    ov2718_write_register(ViPipe, 0x3484, 0x07);
    ov2718_write_register(ViPipe, 0x3485, 0x00);
    ov2718_write_register(ViPipe, 0x3486, 0x00);
    ov2718_write_register(ViPipe, 0x3487, 0x00);
    ov2718_write_register(ViPipe, 0x3488, 0x00);
    ov2718_write_register(ViPipe, 0x3489, 0x00);
    ov2718_write_register(ViPipe, 0x348a, 0x00);
    ov2718_write_register(ViPipe, 0x348b, 0x04);
    ov2718_write_register(ViPipe, 0x348c, 0x00);
    ov2718_write_register(ViPipe, 0x348d, 0x01);
    ov2718_write_register(ViPipe, 0x348f, 0x01);
    ov2718_write_register(ViPipe, 0x7000, 0x1a);
    ov2718_write_register(ViPipe, 0x7001, 0xc1);
    ov2718_write_register(ViPipe, 0x7002, 0x02);
    ov2718_write_register(ViPipe, 0x7003, 0xda);
    ov2718_write_register(ViPipe, 0x7004, 0xbd);
    ov2718_write_register(ViPipe, 0x7005, 0x03);
    ov2718_write_register(ViPipe, 0x7006, 0xbd);
    ov2718_write_register(ViPipe, 0x7007, 0x06);
    ov2718_write_register(ViPipe, 0x7008, 0xe6);
    ov2718_write_register(ViPipe, 0x7009, 0xec);
    ov2718_write_register(ViPipe, 0x700a, 0x19);
    ov2718_write_register(ViPipe, 0x700b, 0xc2);
    ov2718_write_register(ViPipe, 0x700c, 0x0a);
    ov2718_write_register(ViPipe, 0x700d, 0xbc);
    ov2718_write_register(ViPipe, 0x700e, 0xf0);
    ov2718_write_register(ViPipe, 0x700f, 0xbc);
    ov2718_write_register(ViPipe, 0x7010, 0xf0);
    ov2718_write_register(ViPipe, 0x7011, 0x00);
    ov2718_write_register(ViPipe, 0x7012, 0xc0);
    ov2718_write_register(ViPipe, 0x7013, 0x0c);
    ov2718_write_register(ViPipe, 0x7014, 0xbc);
    ov2718_write_register(ViPipe, 0x7015, 0x8c);
    ov2718_write_register(ViPipe, 0x7016, 0xbc);
    ov2718_write_register(ViPipe, 0x7017, 0x14);
    ov2718_write_register(ViPipe, 0x7018, 0xda);
    ov2718_write_register(ViPipe, 0x7019, 0x76);
    ov2718_write_register(ViPipe, 0x701a, 0xb6);
    ov2718_write_register(ViPipe, 0x701b, 0xee);
    ov2718_write_register(ViPipe, 0x701c, 0xcf);
    ov2718_write_register(ViPipe, 0x701d, 0xac);
    ov2718_write_register(ViPipe, 0x701e, 0xd0);
    ov2718_write_register(ViPipe, 0x701f, 0xac);
    ov2718_write_register(ViPipe, 0x7020, 0xd1);
    ov2718_write_register(ViPipe, 0x7021, 0x50);
    ov2718_write_register(ViPipe, 0x7022, 0xac);
    ov2718_write_register(ViPipe, 0x7023, 0xd2);
    ov2718_write_register(ViPipe, 0x7024, 0xbc);
    ov2718_write_register(ViPipe, 0x7025, 0x2e);
    ov2718_write_register(ViPipe, 0x7026, 0xb4);
    ov2718_write_register(ViPipe, 0x7027, 0x00);
    ov2718_write_register(ViPipe, 0x7028, 0xdc);
    ov2718_write_register(ViPipe, 0x7029, 0xdf);
    ov2718_write_register(ViPipe, 0x702a, 0xb0);
    ov2718_write_register(ViPipe, 0x702b, 0x6e);
    ov2718_write_register(ViPipe, 0x702c, 0xbd);
    ov2718_write_register(ViPipe, 0x702d, 0x01);
    ov2718_write_register(ViPipe, 0x702e, 0xd7);
    ov2718_write_register(ViPipe, 0x702f, 0xed);
    ov2718_write_register(ViPipe, 0x7030, 0xe1);
    ov2718_write_register(ViPipe, 0x7031, 0x36);
    ov2718_write_register(ViPipe, 0x7032, 0x30);
    ov2718_write_register(ViPipe, 0x7033, 0xd3);
    ov2718_write_register(ViPipe, 0x7034, 0x2e);
    ov2718_write_register(ViPipe, 0x7035, 0x54);
    ov2718_write_register(ViPipe, 0x7036, 0x46);
    ov2718_write_register(ViPipe, 0x7037, 0xbc);
    ov2718_write_register(ViPipe, 0x7038, 0x22);
    ov2718_write_register(ViPipe, 0x7039, 0x66);
    ov2718_write_register(ViPipe, 0x703a, 0xbc);
    ov2718_write_register(ViPipe, 0x703b, 0x24);
    ov2718_write_register(ViPipe, 0x703c, 0x2c);
    ov2718_write_register(ViPipe, 0x703d, 0x28);
    ov2718_write_register(ViPipe, 0x703e, 0xbc);
    ov2718_write_register(ViPipe, 0x703f, 0x3c);
    ov2718_write_register(ViPipe, 0x7040, 0xa1);
    ov2718_write_register(ViPipe, 0x7041, 0xac);
    ov2718_write_register(ViPipe, 0x7042, 0xd8);
    ov2718_write_register(ViPipe, 0x7043, 0xd6);
    ov2718_write_register(ViPipe, 0x7044, 0xb4);
    ov2718_write_register(ViPipe, 0x7045, 0x04);
    ov2718_write_register(ViPipe, 0x7046, 0x46);
    ov2718_write_register(ViPipe, 0x7047, 0xb7);
    ov2718_write_register(ViPipe, 0x7048, 0x00);
    ov2718_write_register(ViPipe, 0x7049, 0xbe);
    ov2718_write_register(ViPipe, 0x704a, 0x08);
    ov2718_write_register(ViPipe, 0x704b, 0xc3);
    ov2718_write_register(ViPipe, 0x704c, 0xd7);
    ov2718_write_register(ViPipe, 0x704d, 0xad);
    ov2718_write_register(ViPipe, 0x704e, 0xc3);
    ov2718_write_register(ViPipe, 0x704f, 0xbc);
    ov2718_write_register(ViPipe, 0x7050, 0x19);
    ov2718_write_register(ViPipe, 0x7051, 0xc1);
    ov2718_write_register(ViPipe, 0x7052, 0x2a);
    ov2718_write_register(ViPipe, 0x7053, 0xe7);
    ov2718_write_register(ViPipe, 0x7054, 0x50);
    ov2718_write_register(ViPipe, 0x7055, 0x20);
    ov2718_write_register(ViPipe, 0x7056, 0xb8);
    ov2718_write_register(ViPipe, 0x7057, 0x02);
    ov2718_write_register(ViPipe, 0x7058, 0xbc);
    ov2718_write_register(ViPipe, 0x7059, 0x17);
    ov2718_write_register(ViPipe, 0x705a, 0xdb);
    ov2718_write_register(ViPipe, 0x705b, 0xc7);
    ov2718_write_register(ViPipe, 0x705c, 0xb8);
    ov2718_write_register(ViPipe, 0x705d, 0x00);
    ov2718_write_register(ViPipe, 0x705e, 0x28);
    ov2718_write_register(ViPipe, 0x705f, 0x54);
    ov2718_write_register(ViPipe, 0x7060, 0xb4);
    ov2718_write_register(ViPipe, 0x7061, 0x14);
    ov2718_write_register(ViPipe, 0x7062, 0xab);
    ov2718_write_register(ViPipe, 0x7063, 0xbe);
    ov2718_write_register(ViPipe, 0x7064, 0x06);
    ov2718_write_register(ViPipe, 0x7065, 0xd8);
    ov2718_write_register(ViPipe, 0x7066, 0xd6);
    ov2718_write_register(ViPipe, 0x7067, 0x00);
    ov2718_write_register(ViPipe, 0x7068, 0xb4);
    ov2718_write_register(ViPipe, 0x7069, 0xbc);
    ov2718_write_register(ViPipe, 0x706a, 0xb9);
    ov2718_write_register(ViPipe, 0x706b, 0x64);
    ov2718_write_register(ViPipe, 0x706c, 0xbc);
    ov2718_write_register(ViPipe, 0x706d, 0x16);
    ov2718_write_register(ViPipe, 0x706e, 0x62);
    ov2718_write_register(ViPipe, 0x706f, 0x05);
    ov2718_write_register(ViPipe, 0x7070, 0xee);
    ov2718_write_register(ViPipe, 0x7071, 0xe6);
    ov2718_write_register(ViPipe, 0x7072, 0xb9);
    ov2718_write_register(ViPipe, 0x7073, 0x05);
    ov2718_write_register(ViPipe, 0x7074, 0xad);
    ov2718_write_register(ViPipe, 0x7075, 0xb4);
    ov2718_write_register(ViPipe, 0x7076, 0x25);
    ov2718_write_register(ViPipe, 0x7077, 0x19);
    ov2718_write_register(ViPipe, 0x7078, 0xc1);
    ov2718_write_register(ViPipe, 0x7079, 0x3f);
    ov2718_write_register(ViPipe, 0x707a, 0xc3);
    ov2718_write_register(ViPipe, 0x707b, 0xaf);
    ov2718_write_register(ViPipe, 0x707c, 0xc0);
    ov2718_write_register(ViPipe, 0x707d, 0x41);
    ov2718_write_register(ViPipe, 0x707e, 0xc3);
    ov2718_write_register(ViPipe, 0x707f, 0xbe);
    ov2718_write_register(ViPipe, 0x7080, 0xe7);
    ov2718_write_register(ViPipe, 0x7081, 0x00);
    ov2718_write_register(ViPipe, 0x7082, 0x15);
    ov2718_write_register(ViPipe, 0x7083, 0xc2);
    ov2718_write_register(ViPipe, 0x7084, 0x45);
    ov2718_write_register(ViPipe, 0x7085, 0xc3);
    ov2718_write_register(ViPipe, 0x7086, 0xa6);
    ov2718_write_register(ViPipe, 0x7087, 0xc0);
    ov2718_write_register(ViPipe, 0x7088, 0x41);
    ov2718_write_register(ViPipe, 0x7089, 0x00);
    ov2718_write_register(ViPipe, 0x708a, 0x00);
    ov2718_write_register(ViPipe, 0x708b, 0x00);
    ov2718_write_register(ViPipe, 0x708c, 0xb9);
    ov2718_write_register(ViPipe, 0x708d, 0x64);
    ov2718_write_register(ViPipe, 0x708e, 0x29);
    ov2718_write_register(ViPipe, 0x708f, 0x00);
    ov2718_write_register(ViPipe, 0x7090, 0xb8);
    ov2718_write_register(ViPipe, 0x7091, 0x12);
    ov2718_write_register(ViPipe, 0x7092, 0xbe);
    ov2718_write_register(ViPipe, 0x7093, 0x01);
    ov2718_write_register(ViPipe, 0x7094, 0xd0);
    ov2718_write_register(ViPipe, 0x7095, 0xbc);
    ov2718_write_register(ViPipe, 0x7096, 0x01);
    ov2718_write_register(ViPipe, 0x7097, 0xac);
    ov2718_write_register(ViPipe, 0x7098, 0x37);
    ov2718_write_register(ViPipe, 0x7099, 0xd2);
    ov2718_write_register(ViPipe, 0x709a, 0xac);
    ov2718_write_register(ViPipe, 0x709b, 0xad);
    ov2718_write_register(ViPipe, 0x709c, 0x28);
    ov2718_write_register(ViPipe, 0x709d, 0x00);
    ov2718_write_register(ViPipe, 0x709e, 0xb8);
    ov2718_write_register(ViPipe, 0x709f, 0x00);
    ov2718_write_register(ViPipe, 0x70a0, 0xbc);
    ov2718_write_register(ViPipe, 0x70a1, 0x01);
    ov2718_write_register(ViPipe, 0x70a2, 0x36);
    ov2718_write_register(ViPipe, 0x70a3, 0xd3);
    ov2718_write_register(ViPipe, 0x70a4, 0x30);
    ov2718_write_register(ViPipe, 0x70a5, 0x04);
    ov2718_write_register(ViPipe, 0x70a6, 0xe0);
    ov2718_write_register(ViPipe, 0x70a7, 0xd8);
    ov2718_write_register(ViPipe, 0x70a8, 0xb4);
    ov2718_write_register(ViPipe, 0x70a9, 0xcd);
    ov2718_write_register(ViPipe, 0x70aa, 0x45);
    ov2718_write_register(ViPipe, 0x70ab, 0x00);
    ov2718_write_register(ViPipe, 0x70ac, 0xbe);
    ov2718_write_register(ViPipe, 0x70ad, 0x05);
    ov2718_write_register(ViPipe, 0x70ae, 0xbc);
    ov2718_write_register(ViPipe, 0x70af, 0x1e);
    ov2718_write_register(ViPipe, 0x70b0, 0x62);
    ov2718_write_register(ViPipe, 0x70b1, 0x07);
    ov2718_write_register(ViPipe, 0x70b2, 0xb9);
    ov2718_write_register(ViPipe, 0x70b3, 0x05);
    ov2718_write_register(ViPipe, 0x70b4, 0xad);
    ov2718_write_register(ViPipe, 0x70b5, 0xc3);
    ov2718_write_register(ViPipe, 0x70b6, 0xcd);
    ov2718_write_register(ViPipe, 0x70b7, 0x00);
    ov2718_write_register(ViPipe, 0x70b8, 0x15);
    ov2718_write_register(ViPipe, 0x70b9, 0xc2);
    ov2718_write_register(ViPipe, 0x70ba, 0x60);
    ov2718_write_register(ViPipe, 0x70bb, 0xc3);
    ov2718_write_register(ViPipe, 0x70bc, 0xc9);
    ov2718_write_register(ViPipe, 0x70bd, 0xc0);
    ov2718_write_register(ViPipe, 0x70be, 0x5c);
    ov2718_write_register(ViPipe, 0x70bf, 0x00);
    ov2718_write_register(ViPipe, 0x70c0, 0x46);
    ov2718_write_register(ViPipe, 0x70c1, 0x00);
    ov2718_write_register(ViPipe, 0x70c2, 0x00);
    ov2718_write_register(ViPipe, 0x70c3, 0xa1);
    ov2718_write_register(ViPipe, 0x70c4, 0xb9);
    ov2718_write_register(ViPipe, 0x70c5, 0x64);
    ov2718_write_register(ViPipe, 0x70c6, 0x29);
    ov2718_write_register(ViPipe, 0x70c7, 0x00);
    ov2718_write_register(ViPipe, 0x70c8, 0xb8);
    ov2718_write_register(ViPipe, 0x70c9, 0x02);
    ov2718_write_register(ViPipe, 0x70ca, 0xbe);
    ov2718_write_register(ViPipe, 0x70cb, 0x02);
    ov2718_write_register(ViPipe, 0x70cc, 0xd0);
    ov2718_write_register(ViPipe, 0x70cd, 0xdc);
    ov2718_write_register(ViPipe, 0x70ce, 0xac);
    ov2718_write_register(ViPipe, 0x70cf, 0xbc);
    ov2718_write_register(ViPipe, 0x70d0, 0x01);
    ov2718_write_register(ViPipe, 0x70d1, 0x37);
    ov2718_write_register(ViPipe, 0x70d2, 0xac);
    ov2718_write_register(ViPipe, 0x70d3, 0xd2);
    ov2718_write_register(ViPipe, 0x70d4, 0xad);
    ov2718_write_register(ViPipe, 0x70d5, 0x28);
    ov2718_write_register(ViPipe, 0x70d6, 0x00);
    ov2718_write_register(ViPipe, 0x70d7, 0xb8);
    ov2718_write_register(ViPipe, 0x70d8, 0x00);
    ov2718_write_register(ViPipe, 0x70d9, 0xbc);
    ov2718_write_register(ViPipe, 0x70da, 0x01);
    ov2718_write_register(ViPipe, 0x70db, 0x36);
    ov2718_write_register(ViPipe, 0x70dc, 0x30);
    ov2718_write_register(ViPipe, 0x70dd, 0xe0);
    ov2718_write_register(ViPipe, 0x70de, 0xd8);
    ov2718_write_register(ViPipe, 0x70df, 0xb5);
    ov2718_write_register(ViPipe, 0x70e0, 0x06);
    ov2718_write_register(ViPipe, 0x70e1, 0x45);
    ov2718_write_register(ViPipe, 0x70e2, 0xd6);
    ov2718_write_register(ViPipe, 0x70e3, 0xbe);
    ov2718_write_register(ViPipe, 0x70e4, 0x07);
    ov2718_write_register(ViPipe, 0x70e5, 0x00);
    ov2718_write_register(ViPipe, 0x70e6, 0x62);
    ov2718_write_register(ViPipe, 0x70e7, 0x07);
    ov2718_write_register(ViPipe, 0x70e8, 0xb9);
    ov2718_write_register(ViPipe, 0x70e9, 0x05);
    ov2718_write_register(ViPipe, 0x70ea, 0xad);
    ov2718_write_register(ViPipe, 0x70eb, 0xc3);
    ov2718_write_register(ViPipe, 0x70ec, 0xcd);
    ov2718_write_register(ViPipe, 0x70ed, 0x46);
    ov2718_write_register(ViPipe, 0x70ee, 0xcd);
    ov2718_write_register(ViPipe, 0x70ef, 0x07);
    ov2718_write_register(ViPipe, 0x70f0, 0xcd);
    ov2718_write_register(ViPipe, 0x70f1, 0x00);
    ov2718_write_register(ViPipe, 0x70f2, 0xe3);
    ov2718_write_register(ViPipe, 0x70f3, 0x18);
    ov2718_write_register(ViPipe, 0x70f4, 0xc2);
    ov2718_write_register(ViPipe, 0x70f5, 0xa9);
    ov2718_write_register(ViPipe, 0x70f6, 0xb9);
    ov2718_write_register(ViPipe, 0x70f7, 0x64);
    ov2718_write_register(ViPipe, 0x70f8, 0xd1);
    ov2718_write_register(ViPipe, 0x70f9, 0x50);
    ov2718_write_register(ViPipe, 0x70fa, 0xdd);
    ov2718_write_register(ViPipe, 0x70fb, 0xac);
    ov2718_write_register(ViPipe, 0x70fc, 0xcf);
    ov2718_write_register(ViPipe, 0x70fd, 0xdf);
    ov2718_write_register(ViPipe, 0x70fe, 0xb6);
    ov2718_write_register(ViPipe, 0x70ff, 0xee);
    ov2718_write_register(ViPipe, 0x7100, 0xbc);
    ov2718_write_register(ViPipe, 0x7101, 0x13);
    ov2718_write_register(ViPipe, 0x7102, 0xe1);
    ov2718_write_register(ViPipe, 0x7103, 0x36);
    ov2718_write_register(ViPipe, 0x7104, 0x30);
    ov2718_write_register(ViPipe, 0x7105, 0xd3);
    ov2718_write_register(ViPipe, 0x7106, 0x2e);
    ov2718_write_register(ViPipe, 0x7107, 0x54);
    ov2718_write_register(ViPipe, 0x7108, 0xbc);
    ov2718_write_register(ViPipe, 0x7109, 0x32);
    ov2718_write_register(ViPipe, 0x710a, 0x2c);
    ov2718_write_register(ViPipe, 0x710b, 0x50);
    ov2718_write_register(ViPipe, 0x710c, 0x20);
    ov2718_write_register(ViPipe, 0x710d, 0x04);
    ov2718_write_register(ViPipe, 0x710e, 0xb8);
    ov2718_write_register(ViPipe, 0x710f, 0x02);
    ov2718_write_register(ViPipe, 0x7110, 0xbc);
    ov2718_write_register(ViPipe, 0x7111, 0x18);
    ov2718_write_register(ViPipe, 0x7112, 0xc7);
    ov2718_write_register(ViPipe, 0x7113, 0xb8);
    ov2718_write_register(ViPipe, 0x7114, 0x00);
    ov2718_write_register(ViPipe, 0x7115, 0x28);
    ov2718_write_register(ViPipe, 0x7116, 0x54);
    ov2718_write_register(ViPipe, 0x7117, 0xb4);
    ov2718_write_register(ViPipe, 0x7118, 0xbf);
    ov2718_write_register(ViPipe, 0x7119, 0x46);
    ov2718_write_register(ViPipe, 0x711a, 0xbe);
    ov2718_write_register(ViPipe, 0x711b, 0x04);
    ov2718_write_register(ViPipe, 0x711c, 0xd6);
    ov2718_write_register(ViPipe, 0x711d, 0xd8);
    ov2718_write_register(ViPipe, 0x711e, 0xab);
    ov2718_write_register(ViPipe, 0x711f, 0x00);
    ov2718_write_register(ViPipe, 0x7120, 0x62);
    ov2718_write_register(ViPipe, 0x7121, 0x07);
    ov2718_write_register(ViPipe, 0x7122, 0xb9);
    ov2718_write_register(ViPipe, 0x7123, 0x05);
    ov2718_write_register(ViPipe, 0x7124, 0xad);
    ov2718_write_register(ViPipe, 0x7125, 0xc3);
    ov2718_write_register(ViPipe, 0x7126, 0xad);
    ov2718_write_register(ViPipe, 0x7127, 0xb9);
    ov2718_write_register(ViPipe, 0x7128, 0x64);
    ov2718_write_register(ViPipe, 0x7129, 0x29);
    ov2718_write_register(ViPipe, 0x712a, 0x00);
    ov2718_write_register(ViPipe, 0x712b, 0xb8);
    ov2718_write_register(ViPipe, 0x712c, 0x02);
    ov2718_write_register(ViPipe, 0x712d, 0xbe);
    ov2718_write_register(ViPipe, 0x712e, 0x00);
    ov2718_write_register(ViPipe, 0x712f, 0xad);
    ov2718_write_register(ViPipe, 0x7130, 0xe2);
    ov2718_write_register(ViPipe, 0x7131, 0x28);
    ov2718_write_register(ViPipe, 0x7132, 0x00);
    ov2718_write_register(ViPipe, 0x7133, 0xb8);
    ov2718_write_register(ViPipe, 0x7134, 0x00);
    ov2718_write_register(ViPipe, 0x7135, 0xe6);
    ov2718_write_register(ViPipe, 0x7136, 0xbd);
    ov2718_write_register(ViPipe, 0x7137, 0x03);
    ov2718_write_register(ViPipe, 0x7138, 0xec);
    ov2718_write_register(ViPipe, 0x7139, 0xe0);
    ov2718_write_register(ViPipe, 0x713a, 0xd8);
    ov2718_write_register(ViPipe, 0x713b, 0xb4);
    ov2718_write_register(ViPipe, 0x713c, 0xcd);
    ov2718_write_register(ViPipe, 0x713d, 0x45);
    ov2718_write_register(ViPipe, 0x713e, 0xbe);
    ov2718_write_register(ViPipe, 0x713f, 0x03);
    ov2718_write_register(ViPipe, 0x7140, 0x00);
    ov2718_write_register(ViPipe, 0x7141, 0x30);
    ov2718_write_register(ViPipe, 0x7142, 0xbc);
    ov2718_write_register(ViPipe, 0x7143, 0x1c);
    ov2718_write_register(ViPipe, 0x7144, 0x62);
    ov2718_write_register(ViPipe, 0x7145, 0x07);
    ov2718_write_register(ViPipe, 0x7146, 0xb9);
    ov2718_write_register(ViPipe, 0x7147, 0x05);
    ov2718_write_register(ViPipe, 0x7148, 0xad);
    ov2718_write_register(ViPipe, 0x7149, 0xc3);
    ov2718_write_register(ViPipe, 0x714a, 0xcd);
    ov2718_write_register(ViPipe, 0x714b, 0x42);
    ov2718_write_register(ViPipe, 0x714c, 0xe4);
    ov2718_write_register(ViPipe, 0x714d, 0xcd);
    ov2718_write_register(ViPipe, 0x714e, 0x07);
    ov2718_write_register(ViPipe, 0x714f, 0xcd);
    ov2718_write_register(ViPipe, 0x7150, 0x00);
    ov2718_write_register(ViPipe, 0x7151, 0x00);
    ov2718_write_register(ViPipe, 0x7152, 0x17);
    ov2718_write_register(ViPipe, 0x7153, 0xc2);
    ov2718_write_register(ViPipe, 0x7154, 0xc2);
    ov2718_write_register(ViPipe, 0x7155, 0xde);
    ov2718_write_register(ViPipe, 0x7156, 0xcf);
    ov2718_write_register(ViPipe, 0x7157, 0xdf);
    ov2718_write_register(ViPipe, 0x7158, 0xac);
    ov2718_write_register(ViPipe, 0x7159, 0xd1);
    ov2718_write_register(ViPipe, 0x715a, 0x44);
    ov2718_write_register(ViPipe, 0x715b, 0xac);
    ov2718_write_register(ViPipe, 0x715c, 0xb9);
    ov2718_write_register(ViPipe, 0x715d, 0x76);
    ov2718_write_register(ViPipe, 0x715e, 0xb8);
    ov2718_write_register(ViPipe, 0x715f, 0x08);
    ov2718_write_register(ViPipe, 0x7160, 0xb6);
    ov2718_write_register(ViPipe, 0x7161, 0xfe);
    ov2718_write_register(ViPipe, 0x7162, 0xb4);
    ov2718_write_register(ViPipe, 0x7163, 0xbf);
    ov2718_write_register(ViPipe, 0x7164, 0xd6);
    ov2718_write_register(ViPipe, 0x7165, 0xd8);
    ov2718_write_register(ViPipe, 0x7166, 0xab);
    ov2718_write_register(ViPipe, 0x7167, 0x00);
    ov2718_write_register(ViPipe, 0x7168, 0xe1);
    ov2718_write_register(ViPipe, 0x7169, 0x36);
    ov2718_write_register(ViPipe, 0x716a, 0x30);
    ov2718_write_register(ViPipe, 0x716b, 0xd3);
    ov2718_write_register(ViPipe, 0x716c, 0xbc);
    ov2718_write_register(ViPipe, 0x716d, 0x29);
    ov2718_write_register(ViPipe, 0x716e, 0xb4);
    ov2718_write_register(ViPipe, 0x716f, 0x1d);
    ov2718_write_register(ViPipe, 0x7170, 0xaa);
    ov2718_write_register(ViPipe, 0x7171, 0xbd);
    ov2718_write_register(ViPipe, 0x7172, 0x01);
    ov2718_write_register(ViPipe, 0x7173, 0xb8);
    ov2718_write_register(ViPipe, 0x7174, 0x0c);
    ov2718_write_register(ViPipe, 0x7175, 0x45);
    ov2718_write_register(ViPipe, 0x7176, 0xe6);
    ov2718_write_register(ViPipe, 0x7177, 0xbd);
    ov2718_write_register(ViPipe, 0x7178, 0x03);
    ov2718_write_register(ViPipe, 0x7179, 0xec);
    ov2718_write_register(ViPipe, 0x717a, 0xbc);
    ov2718_write_register(ViPipe, 0x717b, 0x3d);
    ov2718_write_register(ViPipe, 0x717c, 0xc3);
    ov2718_write_register(ViPipe, 0x717d, 0xcd);
    ov2718_write_register(ViPipe, 0x717e, 0x42);
    ov2718_write_register(ViPipe, 0x717f, 0xb8);
    ov2718_write_register(ViPipe, 0x7180, 0x00);
    ov2718_write_register(ViPipe, 0x7181, 0xe4);
    ov2718_write_register(ViPipe, 0x7182, 0xd5);
    ov2718_write_register(ViPipe, 0x7183, 0x00);
    ov2718_write_register(ViPipe, 0x7184, 0xb6);
    ov2718_write_register(ViPipe, 0x7185, 0x00);
    ov2718_write_register(ViPipe, 0x7186, 0xbd);
    ov2718_write_register(ViPipe, 0x7187, 0x03);
    ov2718_write_register(ViPipe, 0x7188, 0xb5);
    ov2718_write_register(ViPipe, 0x7189, 0x4b);
    ov2718_write_register(ViPipe, 0x718a, 0x40);
    ov2718_write_register(ViPipe, 0x718b, 0x58);
    ov2718_write_register(ViPipe, 0x718c, 0x6a);
    ov2718_write_register(ViPipe, 0x718d, 0xdd);
    ov2718_write_register(ViPipe, 0x718e, 0x19);
    ov2718_write_register(ViPipe, 0x718f, 0xc1);
    ov2718_write_register(ViPipe, 0x7190, 0xc9);
    ov2718_write_register(ViPipe, 0x7191, 0xe8);
    ov2718_write_register(ViPipe, 0x7192, 0xbc);
    ov2718_write_register(ViPipe, 0x7193, 0x19);
    ov2718_write_register(ViPipe, 0x7194, 0xb9);
    ov2718_write_register(ViPipe, 0x7195, 0xf6);
    ov2718_write_register(ViPipe, 0x7196, 0x14);
    ov2718_write_register(ViPipe, 0x7197, 0xc1);
    ov2718_write_register(ViPipe, 0x7198, 0xd1);
    ov2718_write_register(ViPipe, 0x7199, 0xd1);
    ov2718_write_register(ViPipe, 0x719a, 0xac);
    ov2718_write_register(ViPipe, 0x719b, 0x37);
    ov2718_write_register(ViPipe, 0x719c, 0xbc);
    ov2718_write_register(ViPipe, 0x719d, 0x35);
    ov2718_write_register(ViPipe, 0x719e, 0x36);
    ov2718_write_register(ViPipe, 0x719f, 0x30);
    ov2718_write_register(ViPipe, 0x71a0, 0xe1);
    ov2718_write_register(ViPipe, 0x71a1, 0xd3);
    ov2718_write_register(ViPipe, 0x71a2, 0x7a);
    ov2718_write_register(ViPipe, 0x71a3, 0xb6);
    ov2718_write_register(ViPipe, 0x71a4, 0x0c);
    ov2718_write_register(ViPipe, 0x71a5, 0xff);
    ov2718_write_register(ViPipe, 0x71a6, 0xb4);
    ov2718_write_register(ViPipe, 0x71a7, 0xbc);
    ov2718_write_register(ViPipe, 0x71a8, 0xd9);
    ov2718_write_register(ViPipe, 0x71a9, 0x00);
    ov2718_write_register(ViPipe, 0x71aa, 0x56);
    ov2718_write_register(ViPipe, 0x71ab, 0xc0);
    ov2718_write_register(ViPipe, 0x71ac, 0xda);
    ov2718_write_register(ViPipe, 0x71ad, 0xb4);
    ov2718_write_register(ViPipe, 0x71ae, 0x1d);
    ov2718_write_register(ViPipe, 0x71af, 0x56);
    ov2718_write_register(ViPipe, 0x71b0, 0xaa);
    ov2718_write_register(ViPipe, 0x71b1, 0xbc);
    ov2718_write_register(ViPipe, 0x71b2, 0x08);
    ov2718_write_register(ViPipe, 0x71b3, 0x00);
    ov2718_write_register(ViPipe, 0x71b4, 0x57);
    ov2718_write_register(ViPipe, 0x71b5, 0xe8);
    ov2718_write_register(ViPipe, 0x71b6, 0xb5);
    ov2718_write_register(ViPipe, 0x71b7, 0x48);
    ov2718_write_register(ViPipe, 0x71b8, 0x00);
    ov2718_write_register(ViPipe, 0x71b9, 0x54);
    ov2718_write_register(ViPipe, 0x71ba, 0xe7);
    ov2718_write_register(ViPipe, 0x71bb, 0xc8);
    ov2718_write_register(ViPipe, 0x71bc, 0xb4);
    ov2718_write_register(ViPipe, 0x71bd, 0x1d);
    ov2718_write_register(ViPipe, 0x71be, 0x56);
    ov2718_write_register(ViPipe, 0x71bf, 0xaa);
    ov2718_write_register(ViPipe, 0x71c0, 0xbc);
    ov2718_write_register(ViPipe, 0x71c1, 0x08);
    ov2718_write_register(ViPipe, 0x71c2, 0x57);
    ov2718_write_register(ViPipe, 0x71c3, 0x00);
    ov2718_write_register(ViPipe, 0x71c4, 0xb5);
    ov2718_write_register(ViPipe, 0x71c5, 0x48);
    ov2718_write_register(ViPipe, 0x71c6, 0x00);
    ov2718_write_register(ViPipe, 0x71c7, 0x54);
    ov2718_write_register(ViPipe, 0x71c8, 0xc8);
    ov2718_write_register(ViPipe, 0x71c9, 0xb5);
    ov2718_write_register(ViPipe, 0x71ca, 0x14);
    ov2718_write_register(ViPipe, 0x71cb, 0xd9);
    ov2718_write_register(ViPipe, 0x71cc, 0x00);
    ov2718_write_register(ViPipe, 0x71cd, 0x56);
    ov2718_write_register(ViPipe, 0x71ce, 0x08);
    ov2718_write_register(ViPipe, 0x71cf, 0x57);
    ov2718_write_register(ViPipe, 0x71d0, 0xe8);
    ov2718_write_register(ViPipe, 0x71d1, 0xb4);
    ov2718_write_register(ViPipe, 0x71d2, 0x44);
    ov2718_write_register(ViPipe, 0x71d3, 0x00);
    ov2718_write_register(ViPipe, 0x71d4, 0x54);
    ov2718_write_register(ViPipe, 0x71d5, 0xe7);
    ov2718_write_register(ViPipe, 0x71d6, 0xc8);
    ov2718_write_register(ViPipe, 0x71d7, 0xab);
    ov2718_write_register(ViPipe, 0x71d8, 0x00);
    ov2718_write_register(ViPipe, 0x71d9, 0x66);
    ov2718_write_register(ViPipe, 0x71da, 0x62);
    ov2718_write_register(ViPipe, 0x71db, 0x06);
    ov2718_write_register(ViPipe, 0x71dc, 0x74);
    ov2718_write_register(ViPipe, 0x71dd, 0xb9);
    ov2718_write_register(ViPipe, 0x71de, 0x05);
    ov2718_write_register(ViPipe, 0x71df, 0xb7);
    ov2718_write_register(ViPipe, 0x71e0, 0x10);
    ov2718_write_register(ViPipe, 0x71e1, 0x0e);
    ov2718_write_register(ViPipe, 0x71e2, 0xb7);
    ov2718_write_register(ViPipe, 0x71e3, 0x04);
    ov2718_write_register(ViPipe, 0x71e4, 0xc8);
    ov2718_write_register(ViPipe, 0x7600, 0x04);
    ov2718_write_register(ViPipe, 0x7601, 0x80);
    ov2718_write_register(ViPipe, 0x7602, 0x07);
    ov2718_write_register(ViPipe, 0x7603, 0x44);
    ov2718_write_register(ViPipe, 0x7604, 0x05);
    ov2718_write_register(ViPipe, 0x7605, 0x33);
    ov2718_write_register(ViPipe, 0x7606, 0x0f);
    ov2718_write_register(ViPipe, 0x7607, 0x00);
    ov2718_write_register(ViPipe, 0x7608, 0x07);
    ov2718_write_register(ViPipe, 0x7609, 0x40);
    ov2718_write_register(ViPipe, 0x760a, 0x04);
    ov2718_write_register(ViPipe, 0x760b, 0xe5);
    ov2718_write_register(ViPipe, 0x760c, 0x06);
    ov2718_write_register(ViPipe, 0x760d, 0x50);
    ov2718_write_register(ViPipe, 0x760e, 0x04);
    ov2718_write_register(ViPipe, 0x760f, 0xe4);
    ov2718_write_register(ViPipe, 0x7610, 0x00);
    ov2718_write_register(ViPipe, 0x7611, 0x00);
    ov2718_write_register(ViPipe, 0x7612, 0x06);
    ov2718_write_register(ViPipe, 0x7613, 0x5c);
    ov2718_write_register(ViPipe, 0x7614, 0x00);
    ov2718_write_register(ViPipe, 0x7615, 0x0f);
    ov2718_write_register(ViPipe, 0x7616, 0x06);
    ov2718_write_register(ViPipe, 0x7617, 0x1c);
    ov2718_write_register(ViPipe, 0x7618, 0x00);
    ov2718_write_register(ViPipe, 0x7619, 0x02);
    ov2718_write_register(ViPipe, 0x761a, 0x06);
    ov2718_write_register(ViPipe, 0x761b, 0xa0);
    ov2718_write_register(ViPipe, 0x761c, 0x00);
    ov2718_write_register(ViPipe, 0x761d, 0x01);
    ov2718_write_register(ViPipe, 0x761e, 0x06);
    ov2718_write_register(ViPipe, 0x761f, 0xac);
    ov2718_write_register(ViPipe, 0x7620, 0x00);
    ov2718_write_register(ViPipe, 0x7621, 0x0f);
    ov2718_write_register(ViPipe, 0x7622, 0x05);
    ov2718_write_register(ViPipe, 0x7623, 0x30);
    ov2718_write_register(ViPipe, 0x7624, 0x07);
    ov2718_write_register(ViPipe, 0x7625, 0x00);
    ov2718_write_register(ViPipe, 0x7626, 0x0f);
    ov2718_write_register(ViPipe, 0x7627, 0x00);
    ov2718_write_register(ViPipe, 0x7628, 0x04);
    ov2718_write_register(ViPipe, 0x7629, 0xe5);
    ov2718_write_register(ViPipe, 0x762a, 0x05);
    ov2718_write_register(ViPipe, 0x762b, 0x33);
    ov2718_write_register(ViPipe, 0x762c, 0x06);
    ov2718_write_register(ViPipe, 0x762d, 0x50);
    ov2718_write_register(ViPipe, 0x762e, 0x00);
    ov2718_write_register(ViPipe, 0x762f, 0x01);
    ov2718_write_register(ViPipe, 0x7630, 0x06);
    ov2718_write_register(ViPipe, 0x7631, 0x5c);
    ov2718_write_register(ViPipe, 0x7632, 0x04);
    ov2718_write_register(ViPipe, 0x7633, 0xe4);
    ov2718_write_register(ViPipe, 0x7634, 0x00);
    ov2718_write_register(ViPipe, 0x7635, 0x0e);
    ov2718_write_register(ViPipe, 0x7636, 0x05);
    ov2718_write_register(ViPipe, 0x7637, 0x30);
    ov2718_write_register(ViPipe, 0x7638, 0x0f);
    ov2718_write_register(ViPipe, 0x7639, 0x00);
    ov2718_write_register(ViPipe, 0x763a, 0x06);
    ov2718_write_register(ViPipe, 0x763b, 0x24);
    ov2718_write_register(ViPipe, 0x763c, 0x00);
    ov2718_write_register(ViPipe, 0x763d, 0x03);
    ov2718_write_register(ViPipe, 0x763e, 0x05);
    ov2718_write_register(ViPipe, 0x763f, 0x33);
    ov2718_write_register(ViPipe, 0x7640, 0x07);
    ov2718_write_register(ViPipe, 0x7641, 0x02);
    ov2718_write_register(ViPipe, 0x7642, 0x06);
    ov2718_write_register(ViPipe, 0x7643, 0x24);
    ov2718_write_register(ViPipe, 0x7644, 0x00);
    ov2718_write_register(ViPipe, 0x7645, 0x01);
    ov2718_write_register(ViPipe, 0x7646, 0x06);
    ov2718_write_register(ViPipe, 0x7647, 0x20);
    ov2718_write_register(ViPipe, 0x7648, 0x0f);
    ov2718_write_register(ViPipe, 0x7649, 0x00);
    ov2718_write_register(ViPipe, 0x764a, 0x06);
    ov2718_write_register(ViPipe, 0x764b, 0x14);
    ov2718_write_register(ViPipe, 0x764c, 0x00);
    ov2718_write_register(ViPipe, 0x764d, 0x03);
    ov2718_write_register(ViPipe, 0x764e, 0x05);
    ov2718_write_register(ViPipe, 0x764f, 0x33);
    ov2718_write_register(ViPipe, 0x7650, 0x07);
    ov2718_write_register(ViPipe, 0x7651, 0x02);
    ov2718_write_register(ViPipe, 0x7652, 0x06);
    ov2718_write_register(ViPipe, 0x7653, 0x14);
    ov2718_write_register(ViPipe, 0x7654, 0x00);
    ov2718_write_register(ViPipe, 0x7655, 0x01);
    ov2718_write_register(ViPipe, 0x7656, 0x06);
    ov2718_write_register(ViPipe, 0x7657, 0x10);
    ov2718_write_register(ViPipe, 0x7658, 0x0f);
    ov2718_write_register(ViPipe, 0x7659, 0x00);
    ov2718_write_register(ViPipe, 0x765a, 0x06);
    ov2718_write_register(ViPipe, 0x765b, 0x10);
    ov2718_write_register(ViPipe, 0x765c, 0x0f);
    ov2718_write_register(ViPipe, 0x765d, 0x00);
    ov2718_write_register(ViPipe, 0x765e, 0x06);
    ov2718_write_register(ViPipe, 0x765f, 0x20);
    ov2718_write_register(ViPipe, 0x7660, 0x0f);
    ov2718_write_register(ViPipe, 0x7661, 0x00);
    ov2718_write_register(ViPipe, 0x7662, 0x00);
    ov2718_write_register(ViPipe, 0x7663, 0x00);
    ov2718_write_register(ViPipe, 0x7664, 0x00);
    ov2718_write_register(ViPipe, 0x7665, 0x02);
    ov2718_write_register(ViPipe, 0x7666, 0x04);
    ov2718_write_register(ViPipe, 0x7667, 0xe5);
    ov2718_write_register(ViPipe, 0x7668, 0x04);
    ov2718_write_register(ViPipe, 0x7669, 0xe4);
    ov2718_write_register(ViPipe, 0x766a, 0x0f);
    ov2718_write_register(ViPipe, 0x766b, 0x00);
    ov2718_write_register(ViPipe, 0x766c, 0x00);
    ov2718_write_register(ViPipe, 0x766d, 0x00);
    ov2718_write_register(ViPipe, 0x766e, 0x00);
    ov2718_write_register(ViPipe, 0x766f, 0x02);
    ov2718_write_register(ViPipe, 0x7670, 0x04);
    ov2718_write_register(ViPipe, 0x7671, 0xe5);
    ov2718_write_register(ViPipe, 0x7672, 0x04);
    ov2718_write_register(ViPipe, 0x7673, 0xe4);
    ov2718_write_register(ViPipe, 0x7674, 0x0f);
    ov2718_write_register(ViPipe, 0x7675, 0x00);
    ov2718_write_register(ViPipe, 0x7676, 0x00);
    ov2718_write_register(ViPipe, 0x7677, 0x02);
    ov2718_write_register(ViPipe, 0x7678, 0x04);
    ov2718_write_register(ViPipe, 0x7679, 0xe4);
    ov2718_write_register(ViPipe, 0x767a, 0x00);
    ov2718_write_register(ViPipe, 0x767b, 0x02);
    ov2718_write_register(ViPipe, 0x767c, 0x04);
    ov2718_write_register(ViPipe, 0x767d, 0xc4);
    ov2718_write_register(ViPipe, 0x767e, 0x00);
    ov2718_write_register(ViPipe, 0x767f, 0x04);
    ov2718_write_register(ViPipe, 0x7680, 0x04);
    ov2718_write_register(ViPipe, 0x7681, 0xc4);
    ov2718_write_register(ViPipe, 0x7682, 0x05);
    ov2718_write_register(ViPipe, 0x7683, 0x83);
    ov2718_write_register(ViPipe, 0x7684, 0x07);
    ov2718_write_register(ViPipe, 0x7685, 0x02);
    ov2718_write_register(ViPipe, 0x7686, 0x0f);
    ov2718_write_register(ViPipe, 0x7687, 0x00);
    ov2718_write_register(ViPipe, 0x7688, 0x00);
    ov2718_write_register(ViPipe, 0x7689, 0x02);
    ov2718_write_register(ViPipe, 0x768a, 0x04);
    ov2718_write_register(ViPipe, 0x768b, 0xe4);
    ov2718_write_register(ViPipe, 0x768c, 0x00);
    ov2718_write_register(ViPipe, 0x768d, 0x02);
    ov2718_write_register(ViPipe, 0x768e, 0x04);
    ov2718_write_register(ViPipe, 0x768f, 0xc4);
    ov2718_write_register(ViPipe, 0x7690, 0x00);
    ov2718_write_register(ViPipe, 0x7691, 0x04);
    ov2718_write_register(ViPipe, 0x7692, 0x04);
    ov2718_write_register(ViPipe, 0x7693, 0xc4);
    ov2718_write_register(ViPipe, 0x7694, 0x05);
    ov2718_write_register(ViPipe, 0x7695, 0x83);
    ov2718_write_register(ViPipe, 0x7696, 0x07);
    ov2718_write_register(ViPipe, 0x7697, 0x02);
    ov2718_write_register(ViPipe, 0x7698, 0x03);
    ov2718_write_register(ViPipe, 0x7699, 0x0b);
    ov2718_write_register(ViPipe, 0x769a, 0x05);
    ov2718_write_register(ViPipe, 0x769b, 0x83);
    ov2718_write_register(ViPipe, 0x769c, 0x00);
    ov2718_write_register(ViPipe, 0x769d, 0x08);
    ov2718_write_register(ViPipe, 0x769e, 0x05);
    ov2718_write_register(ViPipe, 0x769f, 0x03);
    ov2718_write_register(ViPipe, 0x76a0, 0x05);
    ov2718_write_register(ViPipe, 0x76a1, 0x32);
    ov2718_write_register(ViPipe, 0x76a2, 0x00);
    ov2718_write_register(ViPipe, 0x76a3, 0x00);
    ov2718_write_register(ViPipe, 0x76a4, 0x05);
    ov2718_write_register(ViPipe, 0x76a5, 0x70);
    ov2718_write_register(ViPipe, 0x76a6, 0x00);
    ov2718_write_register(ViPipe, 0x76a7, 0x01);
    ov2718_write_register(ViPipe, 0x76a8, 0x05);
    ov2718_write_register(ViPipe, 0x76a9, 0x74);
    ov2718_write_register(ViPipe, 0x76aa, 0x03);
    ov2718_write_register(ViPipe, 0x76ab, 0x9a);
    ov2718_write_register(ViPipe, 0x76ac, 0x05);
    ov2718_write_register(ViPipe, 0x76ad, 0x83);
    ov2718_write_register(ViPipe, 0x76ae, 0x00);
    ov2718_write_register(ViPipe, 0x76af, 0x05);
    ov2718_write_register(ViPipe, 0x76b0, 0x05);
    ov2718_write_register(ViPipe, 0x76b1, 0x03);
    ov2718_write_register(ViPipe, 0x76b2, 0x05);
    ov2718_write_register(ViPipe, 0x76b3, 0x32);
    ov2718_write_register(ViPipe, 0x76b4, 0x00);
    ov2718_write_register(ViPipe, 0x76b5, 0x00);
    ov2718_write_register(ViPipe, 0x76b6, 0x05);
    ov2718_write_register(ViPipe, 0x76b7, 0x70);
    ov2718_write_register(ViPipe, 0x76b8, 0x00);
    ov2718_write_register(ViPipe, 0x76b9, 0x01);
    ov2718_write_register(ViPipe, 0x76ba, 0x05);
    ov2718_write_register(ViPipe, 0x76bb, 0x74);
    ov2718_write_register(ViPipe, 0x76bc, 0x03);
    ov2718_write_register(ViPipe, 0x76bd, 0x99);
    ov2718_write_register(ViPipe, 0x76be, 0x05);
    ov2718_write_register(ViPipe, 0x76bf, 0x83);
    ov2718_write_register(ViPipe, 0x76c0, 0x00);
    ov2718_write_register(ViPipe, 0x76c1, 0x03);
    ov2718_write_register(ViPipe, 0x76c2, 0x05);
    ov2718_write_register(ViPipe, 0x76c3, 0x03);
    ov2718_write_register(ViPipe, 0x76c4, 0x05);
    ov2718_write_register(ViPipe, 0x76c5, 0x32);
    ov2718_write_register(ViPipe, 0x76c6, 0x00);
    ov2718_write_register(ViPipe, 0x76c7, 0x00);
    ov2718_write_register(ViPipe, 0x76c8, 0x05);
    ov2718_write_register(ViPipe, 0x76c9, 0x70);
    ov2718_write_register(ViPipe, 0x76ca, 0x00);
    ov2718_write_register(ViPipe, 0x76cb, 0x01);
    ov2718_write_register(ViPipe, 0x76cc, 0x05);
    ov2718_write_register(ViPipe, 0x76cd, 0x74);
    ov2718_write_register(ViPipe, 0x76ce, 0x03);
    ov2718_write_register(ViPipe, 0x76cf, 0x98);
    ov2718_write_register(ViPipe, 0x76d0, 0x05);
    ov2718_write_register(ViPipe, 0x76d1, 0x83);
    ov2718_write_register(ViPipe, 0x76d2, 0x00);
    ov2718_write_register(ViPipe, 0x76d3, 0x01);
    ov2718_write_register(ViPipe, 0x76d4, 0x05);
    ov2718_write_register(ViPipe, 0x76d5, 0x03);
    ov2718_write_register(ViPipe, 0x76d6, 0x05);
    ov2718_write_register(ViPipe, 0x76d7, 0x32);
    ov2718_write_register(ViPipe, 0x76d8, 0x00);
    ov2718_write_register(ViPipe, 0x76d9, 0x00);
    ov2718_write_register(ViPipe, 0x76da, 0x05);
    ov2718_write_register(ViPipe, 0x76db, 0x70);
    ov2718_write_register(ViPipe, 0x76dc, 0x00);
    ov2718_write_register(ViPipe, 0x76dd, 0x01);
    ov2718_write_register(ViPipe, 0x76de, 0x05);
    ov2718_write_register(ViPipe, 0x76df, 0x74);
    ov2718_write_register(ViPipe, 0x76e0, 0x03);
    ov2718_write_register(ViPipe, 0x76e1, 0x97);
    ov2718_write_register(ViPipe, 0x76e2, 0x05);
    ov2718_write_register(ViPipe, 0x76e3, 0x83);
    ov2718_write_register(ViPipe, 0x76e4, 0x00);
    ov2718_write_register(ViPipe, 0x76e5, 0x01);
    ov2718_write_register(ViPipe, 0x76e6, 0x05);
    ov2718_write_register(ViPipe, 0x76e7, 0x03);
    ov2718_write_register(ViPipe, 0x76e8, 0x05);
    ov2718_write_register(ViPipe, 0x76e9, 0x32);
    ov2718_write_register(ViPipe, 0x76ea, 0x00);
    ov2718_write_register(ViPipe, 0x76eb, 0x00);
    ov2718_write_register(ViPipe, 0x76ec, 0x05);
    ov2718_write_register(ViPipe, 0x76ed, 0x70);
    ov2718_write_register(ViPipe, 0x76ee, 0x00);
    ov2718_write_register(ViPipe, 0x76ef, 0x01);
    ov2718_write_register(ViPipe, 0x76f0, 0x05);
    ov2718_write_register(ViPipe, 0x76f1, 0x74);
    ov2718_write_register(ViPipe, 0x76f2, 0x03);
    ov2718_write_register(ViPipe, 0x76f3, 0x96);
    ov2718_write_register(ViPipe, 0x76f4, 0x05);
    ov2718_write_register(ViPipe, 0x76f5, 0x83);
    ov2718_write_register(ViPipe, 0x76f6, 0x00);
    ov2718_write_register(ViPipe, 0x76f7, 0x01);
    ov2718_write_register(ViPipe, 0x76f8, 0x05);
    ov2718_write_register(ViPipe, 0x76f9, 0x03);
    ov2718_write_register(ViPipe, 0x76fa, 0x05);
    ov2718_write_register(ViPipe, 0x76fb, 0x32);
    ov2718_write_register(ViPipe, 0x76fc, 0x00);
    ov2718_write_register(ViPipe, 0x76fd, 0x00);
    ov2718_write_register(ViPipe, 0x76fe, 0x05);
    ov2718_write_register(ViPipe, 0x76ff, 0x70);
    ov2718_write_register(ViPipe, 0x7700, 0x00);
    ov2718_write_register(ViPipe, 0x7701, 0x01);
    ov2718_write_register(ViPipe, 0x7702, 0x05);
    ov2718_write_register(ViPipe, 0x7703, 0x74);
    ov2718_write_register(ViPipe, 0x7704, 0x03);
    ov2718_write_register(ViPipe, 0x7705, 0x95);
    ov2718_write_register(ViPipe, 0x7706, 0x05);
    ov2718_write_register(ViPipe, 0x7707, 0x83);
    ov2718_write_register(ViPipe, 0x7708, 0x00);
    ov2718_write_register(ViPipe, 0x7709, 0x01);
    ov2718_write_register(ViPipe, 0x770a, 0x05);
    ov2718_write_register(ViPipe, 0x770b, 0x03);
    ov2718_write_register(ViPipe, 0x770c, 0x05);
    ov2718_write_register(ViPipe, 0x770d, 0x32);
    ov2718_write_register(ViPipe, 0x770e, 0x00);
    ov2718_write_register(ViPipe, 0x770f, 0x00);
    ov2718_write_register(ViPipe, 0x7710, 0x05);
    ov2718_write_register(ViPipe, 0x7711, 0x70);
    ov2718_write_register(ViPipe, 0x7712, 0x00);
    ov2718_write_register(ViPipe, 0x7713, 0x01);
    ov2718_write_register(ViPipe, 0x7714, 0x05);
    ov2718_write_register(ViPipe, 0x7715, 0x74);
    ov2718_write_register(ViPipe, 0x7716, 0x03);
    ov2718_write_register(ViPipe, 0x7717, 0x94);
    ov2718_write_register(ViPipe, 0x7718, 0x05);
    ov2718_write_register(ViPipe, 0x7719, 0x83);
    ov2718_write_register(ViPipe, 0x771a, 0x00);
    ov2718_write_register(ViPipe, 0x771b, 0x03);
    ov2718_write_register(ViPipe, 0x771c, 0x05);
    ov2718_write_register(ViPipe, 0x771d, 0x03);
    ov2718_write_register(ViPipe, 0x771e, 0x05);
    ov2718_write_register(ViPipe, 0x771f, 0x32);
    ov2718_write_register(ViPipe, 0x7720, 0x00);
    ov2718_write_register(ViPipe, 0x7721, 0x00);
    ov2718_write_register(ViPipe, 0x7722, 0x05);
    ov2718_write_register(ViPipe, 0x7723, 0x70);
    ov2718_write_register(ViPipe, 0x7724, 0x00);
    ov2718_write_register(ViPipe, 0x7725, 0x01);
    ov2718_write_register(ViPipe, 0x7726, 0x05);
    ov2718_write_register(ViPipe, 0x7727, 0x74);
    ov2718_write_register(ViPipe, 0x7728, 0x03);
    ov2718_write_register(ViPipe, 0x7729, 0x93);
    ov2718_write_register(ViPipe, 0x772a, 0x05);
    ov2718_write_register(ViPipe, 0x772b, 0x83);
    ov2718_write_register(ViPipe, 0x772c, 0x00);
    ov2718_write_register(ViPipe, 0x772d, 0x02);
    ov2718_write_register(ViPipe, 0x772e, 0x05);
    ov2718_write_register(ViPipe, 0x772f, 0x03);
    ov2718_write_register(ViPipe, 0x7730, 0x05);
    ov2718_write_register(ViPipe, 0x7731, 0x32);
    ov2718_write_register(ViPipe, 0x7732, 0x00);
    ov2718_write_register(ViPipe, 0x7733, 0x00);
    ov2718_write_register(ViPipe, 0x7734, 0x05);
    ov2718_write_register(ViPipe, 0x7735, 0x70);
    ov2718_write_register(ViPipe, 0x7736, 0x00);
    ov2718_write_register(ViPipe, 0x7737, 0x01);
    ov2718_write_register(ViPipe, 0x7738, 0x05);
    ov2718_write_register(ViPipe, 0x7739, 0x74);
    ov2718_write_register(ViPipe, 0x773a, 0x03);
    ov2718_write_register(ViPipe, 0x773b, 0x92);
    ov2718_write_register(ViPipe, 0x773c, 0x05);
    ov2718_write_register(ViPipe, 0x773d, 0x83);
    ov2718_write_register(ViPipe, 0x773e, 0x00);
    ov2718_write_register(ViPipe, 0x773f, 0x01);
    ov2718_write_register(ViPipe, 0x7740, 0x05);
    ov2718_write_register(ViPipe, 0x7741, 0x03);
    ov2718_write_register(ViPipe, 0x7742, 0x05);
    ov2718_write_register(ViPipe, 0x7743, 0x32);
    ov2718_write_register(ViPipe, 0x7744, 0x00);
    ov2718_write_register(ViPipe, 0x7745, 0x00);
    ov2718_write_register(ViPipe, 0x7746, 0x05);
    ov2718_write_register(ViPipe, 0x7747, 0x70);
    ov2718_write_register(ViPipe, 0x7748, 0x00);
    ov2718_write_register(ViPipe, 0x7749, 0x01);
    ov2718_write_register(ViPipe, 0x774a, 0x05);
    ov2718_write_register(ViPipe, 0x774b, 0x74);
    ov2718_write_register(ViPipe, 0x774c, 0x03);
    ov2718_write_register(ViPipe, 0x774d, 0x91);
    ov2718_write_register(ViPipe, 0x774e, 0x05);
    ov2718_write_register(ViPipe, 0x774f, 0x83);
    ov2718_write_register(ViPipe, 0x7750, 0x00);
    ov2718_write_register(ViPipe, 0x7751, 0x01);
    ov2718_write_register(ViPipe, 0x7752, 0x05);
    ov2718_write_register(ViPipe, 0x7753, 0x03);
    ov2718_write_register(ViPipe, 0x7754, 0x05);
    ov2718_write_register(ViPipe, 0x7755, 0x32);
    ov2718_write_register(ViPipe, 0x7756, 0x00);
    ov2718_write_register(ViPipe, 0x7757, 0x00);
    ov2718_write_register(ViPipe, 0x7758, 0x05);
    ov2718_write_register(ViPipe, 0x7759, 0x70);
    ov2718_write_register(ViPipe, 0x775a, 0x00);
    ov2718_write_register(ViPipe, 0x775b, 0x01);
    ov2718_write_register(ViPipe, 0x775c, 0x05);
    ov2718_write_register(ViPipe, 0x775d, 0x74);
    ov2718_write_register(ViPipe, 0x775e, 0x03);
    ov2718_write_register(ViPipe, 0x775f, 0x90);
    ov2718_write_register(ViPipe, 0x7760, 0x05);
    ov2718_write_register(ViPipe, 0x7761, 0x83);
    ov2718_write_register(ViPipe, 0x7762, 0x00);
    ov2718_write_register(ViPipe, 0x7763, 0x01);
    ov2718_write_register(ViPipe, 0x7764, 0x05);
    ov2718_write_register(ViPipe, 0x7765, 0x03);
    ov2718_write_register(ViPipe, 0x7766, 0x05);
    ov2718_write_register(ViPipe, 0x7767, 0x32);
    ov2718_write_register(ViPipe, 0x7768, 0x00);
    ov2718_write_register(ViPipe, 0x7769, 0x00);
    ov2718_write_register(ViPipe, 0x776a, 0x05);
    ov2718_write_register(ViPipe, 0x776b, 0x70);
    ov2718_write_register(ViPipe, 0x776c, 0x00);
    ov2718_write_register(ViPipe, 0x776d, 0x01);
    ov2718_write_register(ViPipe, 0x776e, 0x05);
    ov2718_write_register(ViPipe, 0x776f, 0x74);
    ov2718_write_register(ViPipe, 0x7770, 0x02);
    ov2718_write_register(ViPipe, 0x7771, 0x90);
    ov2718_write_register(ViPipe, 0x7772, 0x05);
    ov2718_write_register(ViPipe, 0x7773, 0x03);
    ov2718_write_register(ViPipe, 0x7774, 0x07);
    ov2718_write_register(ViPipe, 0x7775, 0x00);
    ov2718_write_register(ViPipe, 0x7776, 0x0f);
    ov2718_write_register(ViPipe, 0x7777, 0x00);
    ov2718_write_register(ViPipe, 0x7778, 0x08);
    ov2718_write_register(ViPipe, 0x7779, 0x31);
    ov2718_write_register(ViPipe, 0x777a, 0x08);
    ov2718_write_register(ViPipe, 0x777b, 0xd2);
    ov2718_write_register(ViPipe, 0x777c, 0x0f);
    ov2718_write_register(ViPipe, 0x777d, 0x00);
    ov2718_write_register(ViPipe, 0x777e, 0x04);
    ov2718_write_register(ViPipe, 0x777f, 0xe5);
    ov2718_write_register(ViPipe, 0x7780, 0x06);
    ov2718_write_register(ViPipe, 0x7781, 0x50);
    ov2718_write_register(ViPipe, 0x7782, 0x04);
    ov2718_write_register(ViPipe, 0x7783, 0xe4);
    ov2718_write_register(ViPipe, 0x7784, 0x00);
    ov2718_write_register(ViPipe, 0x7785, 0x00);
    ov2718_write_register(ViPipe, 0x7786, 0x06);
    ov2718_write_register(ViPipe, 0x7787, 0x5c);
    ov2718_write_register(ViPipe, 0x7788, 0x09);
    ov2718_write_register(ViPipe, 0x7789, 0x15);
    ov2718_write_register(ViPipe, 0x778a, 0x06);
    ov2718_write_register(ViPipe, 0x778b, 0x1c);
    ov2718_write_register(ViPipe, 0x778c, 0x00);
    ov2718_write_register(ViPipe, 0x778d, 0x02);
    ov2718_write_register(ViPipe, 0x778e, 0x06);
    ov2718_write_register(ViPipe, 0x778f, 0xa0);
    ov2718_write_register(ViPipe, 0x7790, 0x00);
    ov2718_write_register(ViPipe, 0x7791, 0x01);
    ov2718_write_register(ViPipe, 0x7792, 0x06);
    ov2718_write_register(ViPipe, 0x7793, 0xac);
    ov2718_write_register(ViPipe, 0x7794, 0x00);
    ov2718_write_register(ViPipe, 0x7795, 0x0f);
    ov2718_write_register(ViPipe, 0x7796, 0x05);
    ov2718_write_register(ViPipe, 0x7797, 0x30);
    ov2718_write_register(ViPipe, 0x7798, 0x0f);
    ov2718_write_register(ViPipe, 0x7799, 0x00);
    ov2718_write_register(ViPipe, 0x779a, 0x00);
    ov2718_write_register(ViPipe, 0x779b, 0x00);
    ov2718_write_register(ViPipe, 0x779c, 0x00);
    ov2718_write_register(ViPipe, 0x779d, 0x02);
    ov2718_write_register(ViPipe, 0x779e, 0x04);
    ov2718_write_register(ViPipe, 0x779f, 0xe5);
    ov2718_write_register(ViPipe, 0x77a0, 0x04);
    ov2718_write_register(ViPipe, 0x77a1, 0xe4);
    ov2718_write_register(ViPipe, 0x77a2, 0x05);
    ov2718_write_register(ViPipe, 0x77a3, 0x33);
    ov2718_write_register(ViPipe, 0x77a4, 0x07);
    ov2718_write_register(ViPipe, 0x77a5, 0x10);
    ov2718_write_register(ViPipe, 0x77a6, 0x00);
    ov2718_write_register(ViPipe, 0x77a7, 0x00);
    ov2718_write_register(ViPipe, 0x77a8, 0x07);
    ov2718_write_register(ViPipe, 0x77a9, 0x00);
    ov2718_write_register(ViPipe, 0x77aa, 0x01);
    ov2718_write_register(ViPipe, 0x77ab, 0xbb);
    ov2718_write_register(ViPipe, 0x77ac, 0x07);
    ov2718_write_register(ViPipe, 0x77ad, 0x10);
    ov2718_write_register(ViPipe, 0x77ae, 0x00);
    ov2718_write_register(ViPipe, 0x77af, 0x00);
    ov2718_write_register(ViPipe, 0x77b0, 0x07);
    ov2718_write_register(ViPipe, 0x77b1, 0x00);
    ov2718_write_register(ViPipe, 0x77b2, 0x01);
    ov2718_write_register(ViPipe, 0x77b3, 0xaa);
    ov2718_write_register(ViPipe, 0x77b4, 0x07);
    ov2718_write_register(ViPipe, 0x77b5, 0x10);
    ov2718_write_register(ViPipe, 0x77b6, 0x00);
    ov2718_write_register(ViPipe, 0x77b7, 0x00);
    ov2718_write_register(ViPipe, 0x77b8, 0x07);
    ov2718_write_register(ViPipe, 0x77b9, 0x00);
    ov2718_write_register(ViPipe, 0x77ba, 0x01);
    ov2718_write_register(ViPipe, 0x77bb, 0x99);
    ov2718_write_register(ViPipe, 0x77bc, 0x07);
    ov2718_write_register(ViPipe, 0x77bd, 0x10);
    ov2718_write_register(ViPipe, 0x77be, 0x00);
    ov2718_write_register(ViPipe, 0x77bf, 0x00);
    ov2718_write_register(ViPipe, 0x77c0, 0x07);
    ov2718_write_register(ViPipe, 0x77c1, 0x00);
    ov2718_write_register(ViPipe, 0x77c2, 0x01);
    ov2718_write_register(ViPipe, 0x77c3, 0x88);
    ov2718_write_register(ViPipe, 0x77c4, 0x07);
    ov2718_write_register(ViPipe, 0x77c5, 0x10);
    ov2718_write_register(ViPipe, 0x77c6, 0x00);
    ov2718_write_register(ViPipe, 0x77c7, 0x00);
    ov2718_write_register(ViPipe, 0x77c8, 0x07);
    ov2718_write_register(ViPipe, 0x77c9, 0x00);
    ov2718_write_register(ViPipe, 0x77ca, 0x01);
    ov2718_write_register(ViPipe, 0x77cb, 0x77);
    ov2718_write_register(ViPipe, 0x77cc, 0x07);
    ov2718_write_register(ViPipe, 0x77cd, 0x10);
    ov2718_write_register(ViPipe, 0x77ce, 0x00);
    ov2718_write_register(ViPipe, 0x77cf, 0x00);
    ov2718_write_register(ViPipe, 0x77d0, 0x07);
    ov2718_write_register(ViPipe, 0x77d1, 0x00);
    ov2718_write_register(ViPipe, 0x77d2, 0x01);
    ov2718_write_register(ViPipe, 0x77d3, 0x66);
    ov2718_write_register(ViPipe, 0x77d4, 0x07);
    ov2718_write_register(ViPipe, 0x77d5, 0x10);
    ov2718_write_register(ViPipe, 0x77d6, 0x00);
    ov2718_write_register(ViPipe, 0x77d7, 0x00);
    ov2718_write_register(ViPipe, 0x77d8, 0x07);
    ov2718_write_register(ViPipe, 0x77d9, 0x00);
    ov2718_write_register(ViPipe, 0x77da, 0x01);
    ov2718_write_register(ViPipe, 0x77db, 0x55);
    ov2718_write_register(ViPipe, 0x77dc, 0x07);
    ov2718_write_register(ViPipe, 0x77dd, 0x10);
    ov2718_write_register(ViPipe, 0x77de, 0x00);
    ov2718_write_register(ViPipe, 0x77df, 0x00);
    ov2718_write_register(ViPipe, 0x77e0, 0x07);
    ov2718_write_register(ViPipe, 0x77e1, 0x00);
    ov2718_write_register(ViPipe, 0x77e2, 0x01);
    ov2718_write_register(ViPipe, 0x77e3, 0x44);
    ov2718_write_register(ViPipe, 0x77e4, 0x07);
    ov2718_write_register(ViPipe, 0x77e5, 0x10);
    ov2718_write_register(ViPipe, 0x77e6, 0x00);
    ov2718_write_register(ViPipe, 0x77e7, 0x00);
    ov2718_write_register(ViPipe, 0x77e8, 0x07);
    ov2718_write_register(ViPipe, 0x77e9, 0x00);
    ov2718_write_register(ViPipe, 0x77ea, 0x01);
    ov2718_write_register(ViPipe, 0x77eb, 0x33);
    ov2718_write_register(ViPipe, 0x77ec, 0x07);
    ov2718_write_register(ViPipe, 0x77ed, 0x10);
    ov2718_write_register(ViPipe, 0x77ee, 0x00);
    ov2718_write_register(ViPipe, 0x77ef, 0x00);
    ov2718_write_register(ViPipe, 0x77f0, 0x07);
    ov2718_write_register(ViPipe, 0x77f1, 0x00);
    ov2718_write_register(ViPipe, 0x77f2, 0x01);
    ov2718_write_register(ViPipe, 0x77f3, 0x22);
    ov2718_write_register(ViPipe, 0x77f4, 0x07);
    ov2718_write_register(ViPipe, 0x77f5, 0x10);
    ov2718_write_register(ViPipe, 0x77f6, 0x00);
    ov2718_write_register(ViPipe, 0x77f7, 0x00);
    ov2718_write_register(ViPipe, 0x77f8, 0x07);
    ov2718_write_register(ViPipe, 0x77f9, 0x00);
    ov2718_write_register(ViPipe, 0x77fa, 0x01);
    ov2718_write_register(ViPipe, 0x77fb, 0x11);
    ov2718_write_register(ViPipe, 0x77fc, 0x07);
    ov2718_write_register(ViPipe, 0x77fd, 0x10);
    ov2718_write_register(ViPipe, 0x77fe, 0x00);
    ov2718_write_register(ViPipe, 0x77ff, 0x00);
    ov2718_write_register(ViPipe, 0x7800, 0x07);
    ov2718_write_register(ViPipe, 0x7801, 0x00);
    ov2718_write_register(ViPipe, 0x7802, 0x01);
    ov2718_write_register(ViPipe, 0x7803, 0x00);
    ov2718_write_register(ViPipe, 0x7804, 0x01);
    ov2718_write_register(ViPipe, 0x7805, 0xff);
    ov2718_write_register(ViPipe, 0x7806, 0x07);
    ov2718_write_register(ViPipe, 0x7807, 0x00);
    ov2718_write_register(ViPipe, 0x7808, 0x02);
    ov2718_write_register(ViPipe, 0x7809, 0xa0);
    ov2718_write_register(ViPipe, 0x780a, 0x0f);
    ov2718_write_register(ViPipe, 0x780b, 0x00);
    ov2718_write_register(ViPipe, 0x780c, 0x08);
    ov2718_write_register(ViPipe, 0x780d, 0x36);
    ov2718_write_register(ViPipe, 0x780e, 0x06);
    ov2718_write_register(ViPipe, 0x780f, 0x50);
    ov2718_write_register(ViPipe, 0x7810, 0x04);
    ov2718_write_register(ViPipe, 0x7811, 0xe4);
    ov2718_write_register(ViPipe, 0x7812, 0x00);
    ov2718_write_register(ViPipe, 0x7813, 0x00);
    ov2718_write_register(ViPipe, 0x7814, 0x05);
    ov2718_write_register(ViPipe, 0x7815, 0x33);
    ov2718_write_register(ViPipe, 0x7816, 0x06);
    ov2718_write_register(ViPipe, 0x7817, 0x5c);
    ov2718_write_register(ViPipe, 0x7818, 0x09);
    ov2718_write_register(ViPipe, 0x7819, 0x15);
    ov2718_write_register(ViPipe, 0x781a, 0x06);
    ov2718_write_register(ViPipe, 0x781b, 0x1c);
    ov2718_write_register(ViPipe, 0x781c, 0x05);
    ov2718_write_register(ViPipe, 0x781d, 0x33);
    ov2718_write_register(ViPipe, 0x781e, 0x00);
    ov2718_write_register(ViPipe, 0x781f, 0x01);
    ov2718_write_register(ViPipe, 0x7820, 0x06);
    ov2718_write_register(ViPipe, 0x7821, 0x24);
    ov2718_write_register(ViPipe, 0x7822, 0x00);
    ov2718_write_register(ViPipe, 0x7823, 0x01);
    ov2718_write_register(ViPipe, 0x7824, 0x06);
    ov2718_write_register(ViPipe, 0x7825, 0x20);
    ov2718_write_register(ViPipe, 0x7826, 0x0f);
    ov2718_write_register(ViPipe, 0x7827, 0x00);
    ov2718_write_register(ViPipe, 0x7828, 0x08);
    ov2718_write_register(ViPipe, 0x7829, 0x36);
    ov2718_write_register(ViPipe, 0x782a, 0x07);
    ov2718_write_register(ViPipe, 0x782b, 0x10);
    ov2718_write_register(ViPipe, 0x782c, 0x00);
    ov2718_write_register(ViPipe, 0x782d, 0x00);
    ov2718_write_register(ViPipe, 0x782e, 0x07);
    ov2718_write_register(ViPipe, 0x782f, 0x00);
    ov2718_write_register(ViPipe, 0x7830, 0x01);
    ov2718_write_register(ViPipe, 0x7831, 0xbb);
    ov2718_write_register(ViPipe, 0x7832, 0x07);
    ov2718_write_register(ViPipe, 0x7833, 0x10);
    ov2718_write_register(ViPipe, 0x7834, 0x00);
    ov2718_write_register(ViPipe, 0x7835, 0x00);
    ov2718_write_register(ViPipe, 0x7836, 0x07);
    ov2718_write_register(ViPipe, 0x7837, 0x00);
    ov2718_write_register(ViPipe, 0x7838, 0x01);
    ov2718_write_register(ViPipe, 0x7839, 0xaa);
    ov2718_write_register(ViPipe, 0x783a, 0x07);
    ov2718_write_register(ViPipe, 0x783b, 0x10);
    ov2718_write_register(ViPipe, 0x783c, 0x00);
    ov2718_write_register(ViPipe, 0x783d, 0x00);
    ov2718_write_register(ViPipe, 0x783e, 0x07);
    ov2718_write_register(ViPipe, 0x783f, 0x00);
    ov2718_write_register(ViPipe, 0x7840, 0x01);
    ov2718_write_register(ViPipe, 0x7841, 0x99);
    ov2718_write_register(ViPipe, 0x7842, 0x07);
    ov2718_write_register(ViPipe, 0x7843, 0x10);
    ov2718_write_register(ViPipe, 0x7844, 0x00);
    ov2718_write_register(ViPipe, 0x7845, 0x00);
    ov2718_write_register(ViPipe, 0x7846, 0x07);
    ov2718_write_register(ViPipe, 0x7847, 0x00);
    ov2718_write_register(ViPipe, 0x7848, 0x01);
    ov2718_write_register(ViPipe, 0x7849, 0x88);
    ov2718_write_register(ViPipe, 0x784a, 0x07);
    ov2718_write_register(ViPipe, 0x784b, 0x10);
    ov2718_write_register(ViPipe, 0x784c, 0x00);
    ov2718_write_register(ViPipe, 0x784d, 0x00);
    ov2718_write_register(ViPipe, 0x784e, 0x07);
    ov2718_write_register(ViPipe, 0x784f, 0x00);
    ov2718_write_register(ViPipe, 0x7850, 0x01);
    ov2718_write_register(ViPipe, 0x7851, 0x77);
    ov2718_write_register(ViPipe, 0x7852, 0x07);
    ov2718_write_register(ViPipe, 0x7853, 0x10);
    ov2718_write_register(ViPipe, 0x7854, 0x00);
    ov2718_write_register(ViPipe, 0x7855, 0x00);
    ov2718_write_register(ViPipe, 0x7856, 0x07);
    ov2718_write_register(ViPipe, 0x7857, 0x00);
    ov2718_write_register(ViPipe, 0x7858, 0x01);
    ov2718_write_register(ViPipe, 0x7859, 0x66);
    ov2718_write_register(ViPipe, 0x785a, 0x07);
    ov2718_write_register(ViPipe, 0x785b, 0x10);
    ov2718_write_register(ViPipe, 0x785c, 0x00);
    ov2718_write_register(ViPipe, 0x785d, 0x00);
    ov2718_write_register(ViPipe, 0x785e, 0x07);
    ov2718_write_register(ViPipe, 0x785f, 0x00);
    ov2718_write_register(ViPipe, 0x7860, 0x01);
    ov2718_write_register(ViPipe, 0x7861, 0x55);
    ov2718_write_register(ViPipe, 0x7862, 0x07);
    ov2718_write_register(ViPipe, 0x7863, 0x10);
    ov2718_write_register(ViPipe, 0x7864, 0x00);
    ov2718_write_register(ViPipe, 0x7865, 0x00);
    ov2718_write_register(ViPipe, 0x7866, 0x07);
    ov2718_write_register(ViPipe, 0x7867, 0x00);
    ov2718_write_register(ViPipe, 0x7868, 0x01);
    ov2718_write_register(ViPipe, 0x7869, 0x44);
    ov2718_write_register(ViPipe, 0x786a, 0x07);
    ov2718_write_register(ViPipe, 0x786b, 0x10);
    ov2718_write_register(ViPipe, 0x786c, 0x00);
    ov2718_write_register(ViPipe, 0x786d, 0x00);
    ov2718_write_register(ViPipe, 0x786e, 0x07);
    ov2718_write_register(ViPipe, 0x786f, 0x00);
    ov2718_write_register(ViPipe, 0x7870, 0x01);
    ov2718_write_register(ViPipe, 0x7871, 0x33);
    ov2718_write_register(ViPipe, 0x7872, 0x07);
    ov2718_write_register(ViPipe, 0x7873, 0x10);
    ov2718_write_register(ViPipe, 0x7874, 0x00);
    ov2718_write_register(ViPipe, 0x7875, 0x00);
    ov2718_write_register(ViPipe, 0x7876, 0x07);
    ov2718_write_register(ViPipe, 0x7877, 0x00);
    ov2718_write_register(ViPipe, 0x7878, 0x01);
    ov2718_write_register(ViPipe, 0x7879, 0x22);
    ov2718_write_register(ViPipe, 0x787a, 0x07);
    ov2718_write_register(ViPipe, 0x787b, 0x10);
    ov2718_write_register(ViPipe, 0x787c, 0x00);
    ov2718_write_register(ViPipe, 0x787d, 0x00);
    ov2718_write_register(ViPipe, 0x787e, 0x07);
    ov2718_write_register(ViPipe, 0x787f, 0x00);
    ov2718_write_register(ViPipe, 0x7880, 0x01);
    ov2718_write_register(ViPipe, 0x7881, 0x11);
    ov2718_write_register(ViPipe, 0x7882, 0x07);
    ov2718_write_register(ViPipe, 0x7883, 0x10);
    ov2718_write_register(ViPipe, 0x7884, 0x00);
    ov2718_write_register(ViPipe, 0x7885, 0x00);
    ov2718_write_register(ViPipe, 0x7886, 0x07);
    ov2718_write_register(ViPipe, 0x7887, 0x00);
    ov2718_write_register(ViPipe, 0x7888, 0x01);
    ov2718_write_register(ViPipe, 0x7889, 0x00);
    ov2718_write_register(ViPipe, 0x788a, 0x01);
    ov2718_write_register(ViPipe, 0x788b, 0xff);
    ov2718_write_register(ViPipe, 0x788c, 0x02);
    ov2718_write_register(ViPipe, 0x788d, 0xa0);
    ov2718_write_register(ViPipe, 0x788e, 0x0f);
    ov2718_write_register(ViPipe, 0x788f, 0x00);
    ov2718_write_register(ViPipe, 0x7890, 0x08);
    ov2718_write_register(ViPipe, 0x7891, 0x3b);
    ov2718_write_register(ViPipe, 0x7892, 0x08);
    ov2718_write_register(ViPipe, 0x7893, 0x5e);
    ov2718_write_register(ViPipe, 0x7894, 0x0f);
    ov2718_write_register(ViPipe, 0x7895, 0x00);
    ov2718_write_register(ViPipe, 0x7896, 0x04);
    ov2718_write_register(ViPipe, 0x7897, 0xc0);
    ov2718_write_register(ViPipe, 0x7898, 0x09);
    ov2718_write_register(ViPipe, 0x7899, 0x15);
    ov2718_write_register(ViPipe, 0x789a, 0x04);
    ov2718_write_register(ViPipe, 0x789b, 0x99);
    ov2718_write_register(ViPipe, 0x789c, 0x07);
    ov2718_write_register(ViPipe, 0x789d, 0x14);
    ov2718_write_register(ViPipe, 0x789e, 0x04);
    ov2718_write_register(ViPipe, 0x789f, 0x80);
    ov2718_write_register(ViPipe, 0x78a0, 0x04);
    ov2718_write_register(ViPipe, 0x78a1, 0xa4);
    ov2718_write_register(ViPipe, 0x78a2, 0x00);
    ov2718_write_register(ViPipe, 0x78a3, 0x0a);
    ov2718_write_register(ViPipe, 0x78a4, 0x04);
    ov2718_write_register(ViPipe, 0x78a5, 0xa6);
    ov2718_write_register(ViPipe, 0x78a6, 0x00);
    ov2718_write_register(ViPipe, 0x78a7, 0x00);
    ov2718_write_register(ViPipe, 0x78a8, 0x04);
    ov2718_write_register(ViPipe, 0x78a9, 0xa0);
    ov2718_write_register(ViPipe, 0x78aa, 0x04);
    ov2718_write_register(ViPipe, 0x78ab, 0x80);
    ov2718_write_register(ViPipe, 0x78ac, 0x04);
    ov2718_write_register(ViPipe, 0x78ad, 0x00);
    ov2718_write_register(ViPipe, 0x78ae, 0x05);
    ov2718_write_register(ViPipe, 0x78af, 0x03);
    ov2718_write_register(ViPipe, 0x78b0, 0x06);
    ov2718_write_register(ViPipe, 0x78b1, 0x00);
    ov2718_write_register(ViPipe, 0x78b2, 0x0f);
    ov2718_write_register(ViPipe, 0x78b3, 0x00);
    ov2718_write_register(ViPipe, 0x78b4, 0x0f);
    ov2718_write_register(ViPipe, 0x78b5, 0x00);
    ov2718_write_register(ViPipe, 0x78b6, 0x0f);
    ov2718_write_register(ViPipe, 0x78b7, 0x00);
    ov2718_write_register(ViPipe, 0x3007, 0x0f);
    ov2718_write_register(ViPipe, 0x3008, 0x03);
    ov2718_write_register(ViPipe, 0x30b0, 0x08);
    ov2718_write_register(ViPipe, 0x30b1, 0x98);
    ov2718_write_register(ViPipe, 0x30b2, 0x04);
    ov2718_write_register(ViPipe, 0x30b3, 0x70);
    ov2718_write_register(ViPipe, 0x3196, 0x00);
    ov2718_write_register(ViPipe, 0x3197, 0x00);
    ov2718_write_register(ViPipe, 0x3195, 0x27);
    ov2718_write_register(ViPipe, 0x30bb, 0x01);
    ov2718_write_register(ViPipe, 0x315a, 0x01);
    ov2718_write_register(ViPipe, 0x315b, 0x80);
    ov2718_write_register(ViPipe, 0x304b, 0x00);
    ov2718_write_register(ViPipe, 0x304d, 0xa4);

    ov2718_default_reg_init(ViPipe);

    ov2718_write_register(ViPipe, 0x3012, 0x01);

    printf("====================================================================\n");
    printf("===ominivision ov2718 sensor HCG 1080P30fps(MIPI port) init success!=====\n");
    printf("====================================================================\n");

    return;
}



/* 1080P30 and 1080P25 */
void ov2718_builtin_1080p30_init(VI_PIPE ViPipe)
{
    delay_ms(5);
    ov2718_write_register(ViPipe, 0x3013, 0x01);
    delay_ms(100);
    ov2718_write_register(ViPipe, 0x3000, 0x05);
    ov2718_write_register(ViPipe, 0x3001, 0x64);
    ov2718_write_register(ViPipe, 0x3002, 0x07);
    ov2718_write_register(ViPipe, 0x3003, 0x01);
    ov2718_write_register(ViPipe, 0x3004, 0x06);
    ov2718_write_register(ViPipe, 0x3005, 0x49);
    ov2718_write_register(ViPipe, 0x3006, 0x00);
    ov2718_write_register(ViPipe, 0x3007, 0x0f);
    ov2718_write_register(ViPipe, 0x3008, 0x03);
    ov2718_write_register(ViPipe, 0x3009, 0x00);
    ov2718_write_register(ViPipe, 0x300c, 0x6c);
    ov2718_write_register(ViPipe, 0x300d, 0xe1);
    ov2718_write_register(ViPipe, 0x300e, 0x80);
    ov2718_write_register(ViPipe, 0x300f, 0x00);
    ov2718_write_register(ViPipe, 0x3012, 0x00);
    ov2718_write_register(ViPipe, 0x3013, 0x00);
    ov2718_write_register(ViPipe, 0x3014, 0x04);
    ov2718_write_register(ViPipe, 0x3015, 0x00);
    ov2718_write_register(ViPipe, 0x3017, 0x00);
    ov2718_write_register(ViPipe, 0x3018, 0x00);
    ov2718_write_register(ViPipe, 0x3019, 0x00);
    ov2718_write_register(ViPipe, 0x301a, 0x00);
    ov2718_write_register(ViPipe, 0x301b, 0x01);
    ov2718_write_register(ViPipe, 0x301e, 0x10);
    ov2718_write_register(ViPipe, 0x301f, 0x5f);
    // ov2718_write_register (ViPipe, 0x3030, 0x02);
    ov2718_write_register(ViPipe, 0x3030, 0x0a);
    ov2718_write_register(ViPipe, 0x3031, 0x62);
    ov2718_write_register(ViPipe, 0x3032, 0xf0);
    ov2718_write_register(ViPipe, 0x3033, 0x30);
    ov2718_write_register(ViPipe, 0x3034, 0x34);
    ov2718_write_register(ViPipe, 0x3035, 0x51);
    ov2718_write_register(ViPipe, 0x3036, 0x02);
    ov2718_write_register(ViPipe, 0x3037, 0x9f);
    ov2718_write_register(ViPipe, 0x3038, 0x04);
    ov2718_write_register(ViPipe, 0x3039, 0xb7);
    ov2718_write_register(ViPipe, 0x303a, 0x04);
    ov2718_write_register(ViPipe, 0x303b, 0x07);
    ov2718_write_register(ViPipe, 0x303c, 0xf0);
    ov2718_write_register(ViPipe, 0x303d, 0x00);
    ov2718_write_register(ViPipe, 0x303e, 0x0b);
    ov2718_write_register(ViPipe, 0x303f, 0xe3);
    ov2718_write_register(ViPipe, 0x3040, 0xf3);
    ov2718_write_register(ViPipe, 0x3041, 0x29);
    ov2718_write_register(ViPipe, 0x3042, 0xf6);
    ov2718_write_register(ViPipe, 0x3043, 0x65);
    ov2718_write_register(ViPipe, 0x3044, 0x06);
    ov2718_write_register(ViPipe, 0x3045, 0x0f);
    ov2718_write_register(ViPipe, 0x3046, 0x55);
    ov2718_write_register(ViPipe, 0x3047, 0xf7);
    ov2718_write_register(ViPipe, 0x3048, 0x31);
    ov2718_write_register(ViPipe, 0x3049, 0x0f);
    ov2718_write_register(ViPipe, 0x304a, 0x10);
    ov2718_write_register(ViPipe, 0x304b, 0xc0);
    ov2718_write_register(ViPipe, 0x304c, 0x33);
    ov2718_write_register(ViPipe, 0x304d, 0xa4);
    ov2718_write_register(ViPipe, 0x304e, 0x0b);
    ov2718_write_register(ViPipe, 0x304f, 0x3d);
    ov2718_write_register(ViPipe, 0x3050, 0x10);
    ov2718_write_register(ViPipe, 0x3060, 0x00);
    ov2718_write_register(ViPipe, 0x3061, 0x64);
    ov2718_write_register(ViPipe, 0x3062, 0x00);
    ov2718_write_register(ViPipe, 0x3063, 0xe4);
    ov2718_write_register(ViPipe, 0x3064, 0x0b);
    ov2718_write_register(ViPipe, 0x3065, 0x60);
    ov2718_write_register(ViPipe, 0x3066, 0x80);
    ov2718_write_register(ViPipe, 0x3080, 0x00);
    ov2718_write_register(ViPipe, 0x3081, 0x00);
    ov2718_write_register(ViPipe, 0x3082, 0x01);
    ov2718_write_register(ViPipe, 0x3083, 0xe3);
    ov2718_write_register(ViPipe, 0x3084, 0x06);
    ov2718_write_register(ViPipe, 0x3085, 0x00);
    ov2718_write_register(ViPipe, 0x3086, 0x10);
    ov2718_write_register(ViPipe, 0x3087, 0x10);
    ov2718_write_register(ViPipe, 0x3089, 0x00);
    ov2718_write_register(ViPipe, 0x308a, 0x01);
    ov2718_write_register(ViPipe, 0x3093, 0x00);
    ov2718_write_register(ViPipe, 0x30a0, 0x00);
    ov2718_write_register(ViPipe, 0x30a1, 0x00);
    ov2718_write_register(ViPipe, 0x30a2, 0x00);
    ov2718_write_register(ViPipe, 0x30a3, 0x00);
    ov2718_write_register(ViPipe, 0x30a4, 0x07);
    ov2718_write_register(ViPipe, 0x30a5, 0x8f);
    ov2718_write_register(ViPipe, 0x30a6, 0x04);
    ov2718_write_register(ViPipe, 0x30a7, 0x47);
    ov2718_write_register(ViPipe, 0x30a8, 0x00);
    ov2718_write_register(ViPipe, 0x30a9, 0x00);
    ov2718_write_register(ViPipe, 0x30aa, 0x00);
    ov2718_write_register(ViPipe, 0x30ab, 0x00);
    ov2718_write_register(ViPipe, 0x30ac, 0x07);
    ov2718_write_register(ViPipe, 0x30ad, 0x90);
    ov2718_write_register(ViPipe, 0x30ae, 0x04);
    ov2718_write_register(ViPipe, 0x30af, 0x48);
    ov2718_write_register(ViPipe, 0x30b0, 0x08);
    ov2718_write_register(ViPipe, 0x30b1, 0x98);
    ov2718_write_register(ViPipe, 0x30b2, 0x04);
    ov2718_write_register(ViPipe, 0x30b3, 0x70);
    ov2718_write_register(ViPipe, 0x30b4, 0x00);
    ov2718_write_register(ViPipe, 0x30b5, 0x00);
    ov2718_write_register(ViPipe, 0x30b6, 0x00);
    ov2718_write_register(ViPipe, 0x30b7, 0x10);
    ov2718_write_register(ViPipe, 0x30b8, 0x00);
    ov2718_write_register(ViPipe, 0x30b9, 0x02);
    ov2718_write_register(ViPipe, 0x30ba, 0x10);
    ov2718_write_register(ViPipe, 0x30bb, 0x00);
    ov2718_write_register(ViPipe, 0x30bc, 0x00);
    ov2718_write_register(ViPipe, 0x30bd, 0x03);
    ov2718_write_register(ViPipe, 0x30be, 0x5c);
    ov2718_write_register(ViPipe, 0x30bf, 0x00);
    ov2718_write_register(ViPipe, 0x30c0, 0x08);
    ov2718_write_register(ViPipe, 0x30c1, 0x00);
    ov2718_write_register(ViPipe, 0x30c2, 0x20);
    ov2718_write_register(ViPipe, 0x30c3, 0x00);
    ov2718_write_register(ViPipe, 0x30c4, 0x4a);
    ov2718_write_register(ViPipe, 0x30c5, 0x00);
    ov2718_write_register(ViPipe, 0x30c7, 0x00);
    ov2718_write_register(ViPipe, 0x30c8, 0x00);
    ov2718_write_register(ViPipe, 0x30d1, 0x00);
    ov2718_write_register(ViPipe, 0x30d2, 0x00);
    ov2718_write_register(ViPipe, 0x30d3, 0x80);
    ov2718_write_register(ViPipe, 0x30d4, 0x00);
    ov2718_write_register(ViPipe, 0x30d9, 0x09);
    ov2718_write_register(ViPipe, 0x30da, 0x64);
    ov2718_write_register(ViPipe, 0x30dd, 0x00);
    ov2718_write_register(ViPipe, 0x30de, 0x16);
    ov2718_write_register(ViPipe, 0x30df, 0x00);
    ov2718_write_register(ViPipe, 0x30e0, 0x17);
    ov2718_write_register(ViPipe, 0x30e1, 0x00);
    ov2718_write_register(ViPipe, 0x30e2, 0x18);
    ov2718_write_register(ViPipe, 0x30e3, 0x10);
    ov2718_write_register(ViPipe, 0x30e4, 0x04);
    ov2718_write_register(ViPipe, 0x30e5, 0x00);
    ov2718_write_register(ViPipe, 0x30e6, 0x00);
    ov2718_write_register(ViPipe, 0x30e7, 0x00);
    ov2718_write_register(ViPipe, 0x30e8, 0x00);
    ov2718_write_register(ViPipe, 0x30e9, 0x00);
    ov2718_write_register(ViPipe, 0x30ea, 0x00);
    ov2718_write_register(ViPipe, 0x30eb, 0x00);
    ov2718_write_register(ViPipe, 0x30ec, 0x00);
    ov2718_write_register(ViPipe, 0x30ed, 0x00);
    ov2718_write_register(ViPipe, 0x3101, 0x00);
    ov2718_write_register(ViPipe, 0x3102, 0x00);
    ov2718_write_register(ViPipe, 0x3103, 0x00);
    ov2718_write_register(ViPipe, 0x3104, 0x00);
    ov2718_write_register(ViPipe, 0x3105, 0x79);
    ov2718_write_register(ViPipe, 0x3106, 0x81);
    ov2718_write_register(ViPipe, 0x3107, 0x75);
    ov2718_write_register(ViPipe, 0x3108, 0x80);
    ov2718_write_register(ViPipe, 0x3109, 0x6c);
    ov2718_write_register(ViPipe, 0x310a, 0x83);
    ov2718_write_register(ViPipe, 0x310b, 0x69);
    ov2718_write_register(ViPipe, 0x310c, 0x43);
    ov2718_write_register(ViPipe, 0x310d, 0x42);
    ov2718_write_register(ViPipe, 0x310e, 0x00);
    ov2718_write_register(ViPipe, 0x3120, 0x00);
    ov2718_write_register(ViPipe, 0x3121, 0x00);
    ov2718_write_register(ViPipe, 0x3122, 0x00);
    ov2718_write_register(ViPipe, 0x3123, 0xf0);
    ov2718_write_register(ViPipe, 0x3124, 0x00);
    ov2718_write_register(ViPipe, 0x3125, 0xa0);
    ov2718_write_register(ViPipe, 0x3126, 0x3f);
    ov2718_write_register(ViPipe, 0x3127, 0x0f);
    ov2718_write_register(ViPipe, 0x3128, 0x00);
    ov2718_write_register(ViPipe, 0x3129, 0x3a);
    ov2718_write_register(ViPipe, 0x312a, 0x02);
    ov2718_write_register(ViPipe, 0x312b, 0x0f);
    ov2718_write_register(ViPipe, 0x312c, 0x00);
    ov2718_write_register(ViPipe, 0x312d, 0x0f);
    ov2718_write_register(ViPipe, 0x312e, 0x1d);
    ov2718_write_register(ViPipe, 0x312f, 0x00);
    ov2718_write_register(ViPipe, 0x3130, 0x00);
    ov2718_write_register(ViPipe, 0x3131, 0x00);
    ov2718_write_register(ViPipe, 0x3132, 0x00);
    ov2718_write_register(ViPipe, 0x3140, 0x02);
    ov2718_write_register(ViPipe, 0x3141, 0x03);
    ov2718_write_register(ViPipe, 0x3142, 0x00);
    ov2718_write_register(ViPipe, 0x3143, 0x00);
    ov2718_write_register(ViPipe, 0x3144, 0x00);
    ov2718_write_register(ViPipe, 0x3145, 0x00);
    ov2718_write_register(ViPipe, 0x3146, 0x00);
    ov2718_write_register(ViPipe, 0x3147, 0x00);
    ov2718_write_register(ViPipe, 0x3148, 0x00);
    ov2718_write_register(ViPipe, 0x3149, 0x00);
    ov2718_write_register(ViPipe, 0x314a, 0x00);
    ov2718_write_register(ViPipe, 0x314b, 0x00);
    ov2718_write_register(ViPipe, 0x314c, 0x00);
    ov2718_write_register(ViPipe, 0x314d, 0x00);
    ov2718_write_register(ViPipe, 0x314e, 0x1c);
    ov2718_write_register(ViPipe, 0x314f, 0x02);
    ov2718_write_register(ViPipe, 0x3150, 0x02);
    ov2718_write_register(ViPipe, 0x3151, 0x02);
    ov2718_write_register(ViPipe, 0x3152, 0x10);
    ov2718_write_register(ViPipe, 0x3153, 0x10);
    ov2718_write_register(ViPipe, 0x3154, 0x10);
    ov2718_write_register(ViPipe, 0x3155, 0x00);
    ov2718_write_register(ViPipe, 0x3156, 0x03);
    ov2718_write_register(ViPipe, 0x3157, 0x00);
    ov2718_write_register(ViPipe, 0x3158, 0x0f);
    ov2718_write_register(ViPipe, 0x3159, 0xff);
    ov2718_write_register(ViPipe, 0x315a, 0x01);
    ov2718_write_register(ViPipe, 0x315b, 0x00);
    ov2718_write_register(ViPipe, 0x315c, 0x01);
    ov2718_write_register(ViPipe, 0x315d, 0x00);
    ov2718_write_register(ViPipe, 0x315e, 0x01);
    ov2718_write_register(ViPipe, 0x315f, 0x00);
    ov2718_write_register(ViPipe, 0x3160, 0x00);
    ov2718_write_register(ViPipe, 0x3161, 0x40);
    ov2718_write_register(ViPipe, 0x3162, 0x00);
    ov2718_write_register(ViPipe, 0x3163, 0x40);
    ov2718_write_register(ViPipe, 0x3164, 0x00);
    ov2718_write_register(ViPipe, 0x3165, 0x40);
    ov2718_write_register(ViPipe, 0x3190, 0x02);
    ov2718_write_register(ViPipe, 0x3191, 0x99);
    ov2718_write_register(ViPipe, 0x3193, 0x08);
    ov2718_write_register(ViPipe, 0x3194, 0x13);
    ov2718_write_register(ViPipe, 0x3195, 0x33);
    ov2718_write_register(ViPipe, 0x3196, 0x00);
    ov2718_write_register(ViPipe, 0x3197, 0x10);
    ov2718_write_register(ViPipe, 0x3198, 0x00);
    ov2718_write_register(ViPipe, 0x3199, 0x7f);
    ov2718_write_register(ViPipe, 0x319a, 0x00);
    ov2718_write_register(ViPipe, 0x319b, 0x00);
    ov2718_write_register(ViPipe, 0x319c, 0x80);
    ov2718_write_register(ViPipe, 0x319d, 0xbf);
    ov2718_write_register(ViPipe, 0x319e, 0xc0);
    ov2718_write_register(ViPipe, 0x319f, 0xff);
    ov2718_write_register(ViPipe, 0x31a0, 0x24);
    ov2718_write_register(ViPipe, 0x31a1, 0x55);
    ov2718_write_register(ViPipe, 0x31a2, 0x00);
    ov2718_write_register(ViPipe, 0x31a3, 0x00);
    ov2718_write_register(ViPipe, 0x31a6, 0x00);
    ov2718_write_register(ViPipe, 0x31a7, 0x00);
    ov2718_write_register(ViPipe, 0x31b0, 0x00);
    ov2718_write_register(ViPipe, 0x31b1, 0x00);
    ov2718_write_register(ViPipe, 0x31b2, 0x02);
    ov2718_write_register(ViPipe, 0x31b3, 0x00);
    ov2718_write_register(ViPipe, 0x31b4, 0x00);
    ov2718_write_register(ViPipe, 0x31b5, 0x01);
    ov2718_write_register(ViPipe, 0x31b6, 0x00);
    ov2718_write_register(ViPipe, 0x31b7, 0x00);
    ov2718_write_register(ViPipe, 0x31b8, 0x00);
    ov2718_write_register(ViPipe, 0x31b9, 0x00);
    ov2718_write_register(ViPipe, 0x31ba, 0x00);
    ov2718_write_register(ViPipe, 0x31d0, 0x3c);
    ov2718_write_register(ViPipe, 0x31d1, 0x34);
    ov2718_write_register(ViPipe, 0x31d2, 0x3c);
    ov2718_write_register(ViPipe, 0x31d3, 0x00);
    ov2718_write_register(ViPipe, 0x31d4, 0x2d);
    ov2718_write_register(ViPipe, 0x31d5, 0x00);
    ov2718_write_register(ViPipe, 0x31d6, 0x01);
    ov2718_write_register(ViPipe, 0x31d7, 0x06);
    ov2718_write_register(ViPipe, 0x31d8, 0x00);
    ov2718_write_register(ViPipe, 0x31d9, 0x64);
    ov2718_write_register(ViPipe, 0x31da, 0x00);
    ov2718_write_register(ViPipe, 0x31db, 0x28);
    ov2718_write_register(ViPipe, 0x31dc, 0x04);
    ov2718_write_register(ViPipe, 0x31dd, 0x69);
    ov2718_write_register(ViPipe, 0x31de, 0x0a);
    ov2718_write_register(ViPipe, 0x31df, 0x3c);
    ov2718_write_register(ViPipe, 0x31e0, 0x04);
    ov2718_write_register(ViPipe, 0x31e1, 0x32);
    ov2718_write_register(ViPipe, 0x31e2, 0x00);
    ov2718_write_register(ViPipe, 0x31e3, 0x01);
    ov2718_write_register(ViPipe, 0x31e4, 0x0d);
    ov2718_write_register(ViPipe, 0x31e5, 0x80);
    ov2718_write_register(ViPipe, 0x31e6, 0x00);
    ov2718_write_register(ViPipe, 0x31e7, 0x2c);
    ov2718_write_register(ViPipe, 0x31e8, 0x6c);
    ov2718_write_register(ViPipe, 0x31e9, 0xac);
    ov2718_write_register(ViPipe, 0x31ea, 0xec);
    ov2718_write_register(ViPipe, 0x31eb, 0x3f);
    ov2718_write_register(ViPipe, 0x31ec, 0x0f);
    ov2718_write_register(ViPipe, 0x31ed, 0x20);
    ov2718_write_register(ViPipe, 0x31ee, 0x04);
    ov2718_write_register(ViPipe, 0x31ef, 0x48);
    ov2718_write_register(ViPipe, 0x31f0, 0x07);
    ov2718_write_register(ViPipe, 0x31f1, 0x90);
    ov2718_write_register(ViPipe, 0x31f2, 0x04);
    ov2718_write_register(ViPipe, 0x31f3, 0x48);
    ov2718_write_register(ViPipe, 0x31f4, 0x07);
    ov2718_write_register(ViPipe, 0x31f5, 0x90);
    ov2718_write_register(ViPipe, 0x31f6, 0x04);
    ov2718_write_register(ViPipe, 0x31f7, 0x48);
    ov2718_write_register(ViPipe, 0x31f8, 0x07);
    ov2718_write_register(ViPipe, 0x31f9, 0x90);
    ov2718_write_register(ViPipe, 0x31fa, 0x04);
    ov2718_write_register(ViPipe, 0x31fb, 0x48);
    ov2718_write_register(ViPipe, 0x31fd, 0xcb);
    ov2718_write_register(ViPipe, 0x31fe, 0x0f);
    ov2718_write_register(ViPipe, 0x31ff, 0x03);
    ov2718_write_register(ViPipe, 0x3200, 0x00);
    ov2718_write_register(ViPipe, 0x3201, 0xff);
    ov2718_write_register(ViPipe, 0x3202, 0x00);
    ov2718_write_register(ViPipe, 0x3203, 0xff);
    ov2718_write_register(ViPipe, 0x3204, 0xff);
    ov2718_write_register(ViPipe, 0x3205, 0xff);
    ov2718_write_register(ViPipe, 0x3206, 0xff);
    ov2718_write_register(ViPipe, 0x3207, 0xff);
    ov2718_write_register(ViPipe, 0x3208, 0xff);
    ov2718_write_register(ViPipe, 0x3209, 0xff);
    ov2718_write_register(ViPipe, 0x320a, 0xff);
    ov2718_write_register(ViPipe, 0x320b, 0x1b);
    ov2718_write_register(ViPipe, 0x320c, 0x1f);
    ov2718_write_register(ViPipe, 0x320d, 0x1e);
    ov2718_write_register(ViPipe, 0x320e, 0x30);
    ov2718_write_register(ViPipe, 0x320f, 0x2d);
    ov2718_write_register(ViPipe, 0x3210, 0x2c);
    ov2718_write_register(ViPipe, 0x3211, 0x2b);
    ov2718_write_register(ViPipe, 0x3212, 0x2a);
    ov2718_write_register(ViPipe, 0x3213, 0x24);
    ov2718_write_register(ViPipe, 0x3214, 0x22);
    ov2718_write_register(ViPipe, 0x3215, 0x00);
    ov2718_write_register(ViPipe, 0x3216, 0x04);
    ov2718_write_register(ViPipe, 0x3217, 0x2c);
    ov2718_write_register(ViPipe, 0x3218, 0x6c);
    ov2718_write_register(ViPipe, 0x3219, 0xac);
    ov2718_write_register(ViPipe, 0x321a, 0xec);
    ov2718_write_register(ViPipe, 0x321b, 0x00);
    ov2718_write_register(ViPipe, 0x3230, 0x3a);
    ov2718_write_register(ViPipe, 0x3231, 0x00);
    ov2718_write_register(ViPipe, 0x3232, 0x80);
    ov2718_write_register(ViPipe, 0x3233, 0x00);
    ov2718_write_register(ViPipe, 0x3234, 0x10);
    ov2718_write_register(ViPipe, 0x3235, 0xaa);
    ov2718_write_register(ViPipe, 0x3236, 0x55);
    ov2718_write_register(ViPipe, 0x3237, 0x99);
    ov2718_write_register(ViPipe, 0x3238, 0x66);
    ov2718_write_register(ViPipe, 0x3239, 0x08);
    ov2718_write_register(ViPipe, 0x323a, 0x88);
    ov2718_write_register(ViPipe, 0x323b, 0x00);
    ov2718_write_register(ViPipe, 0x323c, 0x00);
    ov2718_write_register(ViPipe, 0x323d, 0x03);
    ov2718_write_register(ViPipe, 0x3250, 0x33);
    ov2718_write_register(ViPipe, 0x3251, 0x00);
    ov2718_write_register(ViPipe, 0x3252, 0x20);
    ov2718_write_register(ViPipe, 0x3253, 0x00);
    ov2718_write_register(ViPipe, 0x3254, 0x11);
    ov2718_write_register(ViPipe, 0x3255, 0x01);
    ov2718_write_register(ViPipe, 0x3256, 0x00);
    ov2718_write_register(ViPipe, 0x3257, 0x00);
    ov2718_write_register(ViPipe, 0x3258, 0x00);
    ov2718_write_register(ViPipe, 0x3270, 0x01);
    ov2718_write_register(ViPipe, 0x3271, 0x60);
    ov2718_write_register(ViPipe, 0x3272, 0xc0);
    ov2718_write_register(ViPipe, 0x3273, 0x00);
    ov2718_write_register(ViPipe, 0x3274, 0x80);
    ov2718_write_register(ViPipe, 0x3275, 0x40);
    ov2718_write_register(ViPipe, 0x3276, 0x02);
    ov2718_write_register(ViPipe, 0x3277, 0x08);
    ov2718_write_register(ViPipe, 0x3278, 0x10);
    ov2718_write_register(ViPipe, 0x3279, 0x04);
    ov2718_write_register(ViPipe, 0x327a, 0x00);
    ov2718_write_register(ViPipe, 0x327b, 0x03);
    ov2718_write_register(ViPipe, 0x327c, 0x10);
    ov2718_write_register(ViPipe, 0x327d, 0x60);
    ov2718_write_register(ViPipe, 0x327e, 0xc0);
    ov2718_write_register(ViPipe, 0x327f, 0x06);
    ov2718_write_register(ViPipe, 0x3288, 0x10);
    ov2718_write_register(ViPipe, 0x3289, 0x00);
    ov2718_write_register(ViPipe, 0x328a, 0x08);
    ov2718_write_register(ViPipe, 0x328b, 0x00);
    ov2718_write_register(ViPipe, 0x328c, 0x04);
    ov2718_write_register(ViPipe, 0x328d, 0x00);
    ov2718_write_register(ViPipe, 0x328e, 0x02);
    ov2718_write_register(ViPipe, 0x328f, 0x00);
    ov2718_write_register(ViPipe, 0x3290, 0x20);
    ov2718_write_register(ViPipe, 0x3291, 0x00);
    ov2718_write_register(ViPipe, 0x3292, 0x10);
    ov2718_write_register(ViPipe, 0x3293, 0x00);
    ov2718_write_register(ViPipe, 0x3294, 0x08);
    ov2718_write_register(ViPipe, 0x3295, 0x00);
    ov2718_write_register(ViPipe, 0x3296, 0x04);
    ov2718_write_register(ViPipe, 0x3297, 0x00);
    ov2718_write_register(ViPipe, 0x3298, 0x40);
    ov2718_write_register(ViPipe, 0x3299, 0x00);
    ov2718_write_register(ViPipe, 0x329a, 0x20);
    ov2718_write_register(ViPipe, 0x329b, 0x00);
    ov2718_write_register(ViPipe, 0x329c, 0x10);
    ov2718_write_register(ViPipe, 0x329d, 0x00);
    ov2718_write_register(ViPipe, 0x329e, 0x08);
    ov2718_write_register(ViPipe, 0x329f, 0x00);
    ov2718_write_register(ViPipe, 0x32a0, 0x7f);
    ov2718_write_register(ViPipe, 0x32a1, 0xff);
    ov2718_write_register(ViPipe, 0x32a2, 0x40);
    ov2718_write_register(ViPipe, 0x32a3, 0x00);
    ov2718_write_register(ViPipe, 0x32a4, 0x20);
    ov2718_write_register(ViPipe, 0x32a5, 0x00);
    ov2718_write_register(ViPipe, 0x32a6, 0x10);
    ov2718_write_register(ViPipe, 0x32a7, 0x00);
    ov2718_write_register(ViPipe, 0x32a8, 0x00);
    ov2718_write_register(ViPipe, 0x32a9, 0x00);
    ov2718_write_register(ViPipe, 0x32aa, 0x00);
    ov2718_write_register(ViPipe, 0x32ab, 0x00);
    ov2718_write_register(ViPipe, 0x32ac, 0x00);
    ov2718_write_register(ViPipe, 0x32ad, 0x00);
    ov2718_write_register(ViPipe, 0x32ae, 0x00);
    ov2718_write_register(ViPipe, 0x32af, 0x00);
    ov2718_write_register(ViPipe, 0x32b0, 0x00);
    ov2718_write_register(ViPipe, 0x32b1, 0x00);
    ov2718_write_register(ViPipe, 0x32b2, 0x00);
    ov2718_write_register(ViPipe, 0x32b3, 0x00);
    ov2718_write_register(ViPipe, 0x32b4, 0x00);
    ov2718_write_register(ViPipe, 0x32b5, 0x00);
    ov2718_write_register(ViPipe, 0x32b6, 0x00);
    ov2718_write_register(ViPipe, 0x32b7, 0x00);
    ov2718_write_register(ViPipe, 0x32b8, 0x00);
    ov2718_write_register(ViPipe, 0x32b9, 0x00);
    ov2718_write_register(ViPipe, 0x32ba, 0x00);
    ov2718_write_register(ViPipe, 0x32bb, 0x00);
    ov2718_write_register(ViPipe, 0x32bc, 0x00);
    ov2718_write_register(ViPipe, 0x32bd, 0x00);
    ov2718_write_register(ViPipe, 0x32be, 0x00);
    ov2718_write_register(ViPipe, 0x32bf, 0x00);
    ov2718_write_register(ViPipe, 0x32c0, 0x00);
    ov2718_write_register(ViPipe, 0x32c1, 0x00);
    ov2718_write_register(ViPipe, 0x32c2, 0x00);
    ov2718_write_register(ViPipe, 0x32c3, 0x00);
    ov2718_write_register(ViPipe, 0x32c4, 0x00);
    ov2718_write_register(ViPipe, 0x32c5, 0x00);
    ov2718_write_register(ViPipe, 0x32c6, 0x00);
    ov2718_write_register(ViPipe, 0x32c7, 0x00);
    ov2718_write_register(ViPipe, 0x32c8, 0x87);
    ov2718_write_register(ViPipe, 0x32c9, 0x00);
    ov2718_write_register(ViPipe, 0x3330, 0x03);
    ov2718_write_register(ViPipe, 0x3331, 0xc8);
    ov2718_write_register(ViPipe, 0x3332, 0x02);
    ov2718_write_register(ViPipe, 0x3333, 0x24);
    ov2718_write_register(ViPipe, 0x3334, 0x00);
    ov2718_write_register(ViPipe, 0x3335, 0x00);
    ov2718_write_register(ViPipe, 0x3336, 0x00);
    ov2718_write_register(ViPipe, 0x3337, 0x00);
    ov2718_write_register(ViPipe, 0x3338, 0x03);
    ov2718_write_register(ViPipe, 0x3339, 0xc8);
    ov2718_write_register(ViPipe, 0x333a, 0x02);
    ov2718_write_register(ViPipe, 0x333b, 0x24);
    ov2718_write_register(ViPipe, 0x333c, 0x00);
    ov2718_write_register(ViPipe, 0x333d, 0x00);
    ov2718_write_register(ViPipe, 0x333e, 0x00);
    ov2718_write_register(ViPipe, 0x333f, 0x00);
    ov2718_write_register(ViPipe, 0x3340, 0x03);
    ov2718_write_register(ViPipe, 0x3341, 0xc8);
    ov2718_write_register(ViPipe, 0x3342, 0x02);
    ov2718_write_register(ViPipe, 0x3343, 0x24);
    ov2718_write_register(ViPipe, 0x3344, 0x00);
    ov2718_write_register(ViPipe, 0x3345, 0x00);
    ov2718_write_register(ViPipe, 0x3346, 0x00);
    ov2718_write_register(ViPipe, 0x3347, 0x00);
    ov2718_write_register(ViPipe, 0x3348, 0x40);
    ov2718_write_register(ViPipe, 0x3349, 0x00);
    ov2718_write_register(ViPipe, 0x334a, 0x00);
    ov2718_write_register(ViPipe, 0x334b, 0x00);
    ov2718_write_register(ViPipe, 0x334c, 0x00);
    ov2718_write_register(ViPipe, 0x334d, 0x00);
    ov2718_write_register(ViPipe, 0x334e, 0x80);
    ov2718_write_register(ViPipe, 0x3360, 0x01);
    ov2718_write_register(ViPipe, 0x3361, 0x00);
    ov2718_write_register(ViPipe, 0x3362, 0x01);
    ov2718_write_register(ViPipe, 0x3363, 0x00);
    ov2718_write_register(ViPipe, 0x3364, 0x01);
    ov2718_write_register(ViPipe, 0x3365, 0x00);
    ov2718_write_register(ViPipe, 0x3366, 0x01);
    ov2718_write_register(ViPipe, 0x3367, 0x00);
    ov2718_write_register(ViPipe, 0x3368, 0x01);
    ov2718_write_register(ViPipe, 0x3369, 0x00);
    ov2718_write_register(ViPipe, 0x336a, 0x01);
    ov2718_write_register(ViPipe, 0x336b, 0x00);
    ov2718_write_register(ViPipe, 0x336c, 0x01);
    ov2718_write_register(ViPipe, 0x336d, 0x00);
    ov2718_write_register(ViPipe, 0x336e, 0x01);
    ov2718_write_register(ViPipe, 0x336f, 0x00);
    ov2718_write_register(ViPipe, 0x3370, 0x01);
    ov2718_write_register(ViPipe, 0x3371, 0x00);
    ov2718_write_register(ViPipe, 0x3372, 0x01);
    ov2718_write_register(ViPipe, 0x3373, 0x00);
    ov2718_write_register(ViPipe, 0x3374, 0x01);
    ov2718_write_register(ViPipe, 0x3375, 0x00);
    ov2718_write_register(ViPipe, 0x3376, 0x01);
    ov2718_write_register(ViPipe, 0x3377, 0x00);
    ov2718_write_register(ViPipe, 0x3378, 0x00);
    ov2718_write_register(ViPipe, 0x3379, 0x00);
    ov2718_write_register(ViPipe, 0x337a, 0x00);
    ov2718_write_register(ViPipe, 0x337b, 0x00);
    ov2718_write_register(ViPipe, 0x337c, 0x00);
    ov2718_write_register(ViPipe, 0x337d, 0x00);
    ov2718_write_register(ViPipe, 0x337e, 0x00);
    ov2718_write_register(ViPipe, 0x337f, 0x00);
    ov2718_write_register(ViPipe, 0x3380, 0x00);
    ov2718_write_register(ViPipe, 0x3381, 0x00);
    ov2718_write_register(ViPipe, 0x3382, 0x00);
    ov2718_write_register(ViPipe, 0x3383, 0x00);
    ov2718_write_register(ViPipe, 0x3384, 0x00);
    ov2718_write_register(ViPipe, 0x3385, 0x00);
    ov2718_write_register(ViPipe, 0x3386, 0x00);
    ov2718_write_register(ViPipe, 0x3387, 0x00);
    ov2718_write_register(ViPipe, 0x3388, 0x00);
    ov2718_write_register(ViPipe, 0x3389, 0x00);
    ov2718_write_register(ViPipe, 0x338a, 0x00);
    ov2718_write_register(ViPipe, 0x338b, 0x00);
    ov2718_write_register(ViPipe, 0x338c, 0x00);
    ov2718_write_register(ViPipe, 0x338d, 0x00);
    ov2718_write_register(ViPipe, 0x338e, 0x00);
    ov2718_write_register(ViPipe, 0x338f, 0x00);
    ov2718_write_register(ViPipe, 0x3390, 0x00);
    ov2718_write_register(ViPipe, 0x3391, 0x00);
    ov2718_write_register(ViPipe, 0x3392, 0x00);
    ov2718_write_register(ViPipe, 0x3393, 0x00);
    ov2718_write_register(ViPipe, 0x3394, 0x00);
    ov2718_write_register(ViPipe, 0x3395, 0x00);
    ov2718_write_register(ViPipe, 0x3396, 0x00);
    ov2718_write_register(ViPipe, 0x3397, 0x00);
    ov2718_write_register(ViPipe, 0x3398, 0x00);
    ov2718_write_register(ViPipe, 0x3399, 0x00);
    ov2718_write_register(ViPipe, 0x339a, 0x00);
    ov2718_write_register(ViPipe, 0x339b, 0x00);
    ov2718_write_register(ViPipe, 0x33b0, 0x00);
    ov2718_write_register(ViPipe, 0x33b1, 0x50);
    ov2718_write_register(ViPipe, 0x33b2, 0x01);
    ov2718_write_register(ViPipe, 0x33b3, 0xff);
    ov2718_write_register(ViPipe, 0x33b4, 0xe0);
    ov2718_write_register(ViPipe, 0x33b5, 0x6b);
    ov2718_write_register(ViPipe, 0x33b6, 0x00);
    ov2718_write_register(ViPipe, 0x33b7, 0x00);
    ov2718_write_register(ViPipe, 0x33b8, 0x00);
    ov2718_write_register(ViPipe, 0x33b9, 0x00);
    ov2718_write_register(ViPipe, 0x33ba, 0x02);
    ov2718_write_register(ViPipe, 0x33bb, 0x08);
    ov2718_write_register(ViPipe, 0x33bc, 0x01);
    ov2718_write_register(ViPipe, 0x33bd, 0x01);
    ov2718_write_register(ViPipe, 0x33be, 0x01);
    ov2718_write_register(ViPipe, 0x33bf, 0x01);
    ov2718_write_register(ViPipe, 0x33c0, 0x00);
    ov2718_write_register(ViPipe, 0x33c1, 0x00);
    ov2718_write_register(ViPipe, 0x33c2, 0x00);
    ov2718_write_register(ViPipe, 0x33c3, 0x00);
    ov2718_write_register(ViPipe, 0x33e0, 0x14);
    ov2718_write_register(ViPipe, 0x33e1, 0x0f);
    ov2718_write_register(ViPipe, 0x33e2, 0x04);
    ov2718_write_register(ViPipe, 0x33e3, 0x02);
    ov2718_write_register(ViPipe, 0x33e4, 0x01);
    ov2718_write_register(ViPipe, 0x33e5, 0x01);
    ov2718_write_register(ViPipe, 0x33e6, 0x00);
    ov2718_write_register(ViPipe, 0x33e7, 0x04);
    ov2718_write_register(ViPipe, 0x33e8, 0x0c);
    ov2718_write_register(ViPipe, 0x33e9, 0x00);
    ov2718_write_register(ViPipe, 0x33ea, 0x01);
    ov2718_write_register(ViPipe, 0x33eb, 0x02);
    ov2718_write_register(ViPipe, 0x33ec, 0x03);
    ov2718_write_register(ViPipe, 0x33ed, 0x02);
    ov2718_write_register(ViPipe, 0x33ee, 0x05);
    ov2718_write_register(ViPipe, 0x33ef, 0x0a);
    ov2718_write_register(ViPipe, 0x33f0, 0x08);
    ov2718_write_register(ViPipe, 0x33f1, 0x04);
    ov2718_write_register(ViPipe, 0x33f2, 0x04);
    ov2718_write_register(ViPipe, 0x33f3, 0x00);
    ov2718_write_register(ViPipe, 0x33f4, 0x03);
    ov2718_write_register(ViPipe, 0x33f5, 0x14);
    ov2718_write_register(ViPipe, 0x33f6, 0x0f);
    ov2718_write_register(ViPipe, 0x33f7, 0x02);
    ov2718_write_register(ViPipe, 0x33f8, 0x01);
    ov2718_write_register(ViPipe, 0x33f9, 0x01);
    ov2718_write_register(ViPipe, 0x33fa, 0x01);
    ov2718_write_register(ViPipe, 0x33fb, 0x00);
    ov2718_write_register(ViPipe, 0x33fc, 0x04);
    ov2718_write_register(ViPipe, 0x33fd, 0x0c);
    ov2718_write_register(ViPipe, 0x33fe, 0x00);
    ov2718_write_register(ViPipe, 0x33ff, 0x01);
    ov2718_write_register(ViPipe, 0x3400, 0x02);
    ov2718_write_register(ViPipe, 0x3401, 0x03);
    ov2718_write_register(ViPipe, 0x3402, 0x01);
    ov2718_write_register(ViPipe, 0x3403, 0x02);
    ov2718_write_register(ViPipe, 0x3404, 0x08);
    ov2718_write_register(ViPipe, 0x3405, 0x08);
    ov2718_write_register(ViPipe, 0x3406, 0x04);
    ov2718_write_register(ViPipe, 0x3407, 0x04);
    ov2718_write_register(ViPipe, 0x3408, 0x00);
    ov2718_write_register(ViPipe, 0x3409, 0x03);
    ov2718_write_register(ViPipe, 0x340a, 0x14);
    ov2718_write_register(ViPipe, 0x340b, 0x0f);
    ov2718_write_register(ViPipe, 0x340c, 0x04);
    ov2718_write_register(ViPipe, 0x340d, 0x02);
    ov2718_write_register(ViPipe, 0x340e, 0x01);
    ov2718_write_register(ViPipe, 0x340f, 0x01);
    ov2718_write_register(ViPipe, 0x3410, 0x00);
    ov2718_write_register(ViPipe, 0x3411, 0x04);
    ov2718_write_register(ViPipe, 0x3412, 0x0c);
    ov2718_write_register(ViPipe, 0x3413, 0x00);
    ov2718_write_register(ViPipe, 0x3414, 0x01);
    ov2718_write_register(ViPipe, 0x3415, 0x02);
    ov2718_write_register(ViPipe, 0x3416, 0x03);
    ov2718_write_register(ViPipe, 0x3417, 0x02);
    ov2718_write_register(ViPipe, 0x3418, 0x05);
    ov2718_write_register(ViPipe, 0x3419, 0x0a);
    ov2718_write_register(ViPipe, 0x341a, 0x08);
    ov2718_write_register(ViPipe, 0x341b, 0x04);
    ov2718_write_register(ViPipe, 0x341c, 0x04);
    ov2718_write_register(ViPipe, 0x341d, 0x00);
    ov2718_write_register(ViPipe, 0x341e, 0x03);
    ov2718_write_register(ViPipe, 0x3440, 0x00);
    ov2718_write_register(ViPipe, 0x3441, 0x00);
    ov2718_write_register(ViPipe, 0x3442, 0x00);
    ov2718_write_register(ViPipe, 0x3443, 0x00);
    ov2718_write_register(ViPipe, 0x3444, 0x02);
    ov2718_write_register(ViPipe, 0x3445, 0xf0);
    ov2718_write_register(ViPipe, 0x3446, 0x02);
    ov2718_write_register(ViPipe, 0x3447, 0x08);
    ov2718_write_register(ViPipe, 0x3448, 0x00);
    ov2718_write_register(ViPipe, 0x3460, 0x40);
    ov2718_write_register(ViPipe, 0x3461, 0x40);
    ov2718_write_register(ViPipe, 0x3462, 0x40);
    ov2718_write_register(ViPipe, 0x3463, 0x40);
    ov2718_write_register(ViPipe, 0x3464, 0x03);
    ov2718_write_register(ViPipe, 0x3465, 0x01);
    ov2718_write_register(ViPipe, 0x3466, 0x01);
    ov2718_write_register(ViPipe, 0x3467, 0x02);
    ov2718_write_register(ViPipe, 0x3468, 0x30);
    ov2718_write_register(ViPipe, 0x3469, 0x00);
    ov2718_write_register(ViPipe, 0x346a, 0x35);
    ov2718_write_register(ViPipe, 0x346b, 0x00);
    ov2718_write_register(ViPipe, 0x3480, 0x40);
    ov2718_write_register(ViPipe, 0x3481, 0x00);
    ov2718_write_register(ViPipe, 0x3482, 0x00);
    ov2718_write_register(ViPipe, 0x3483, 0x00);
    ov2718_write_register(ViPipe, 0x3484, 0x07);
    ov2718_write_register(ViPipe, 0x3485, 0x00);
    ov2718_write_register(ViPipe, 0x3486, 0x00);
    ov2718_write_register(ViPipe, 0x3487, 0x00);
    ov2718_write_register(ViPipe, 0x3488, 0x00);
    ov2718_write_register(ViPipe, 0x3489, 0x00);
    ov2718_write_register(ViPipe, 0x348a, 0x00);
    ov2718_write_register(ViPipe, 0x348b, 0x04);
    ov2718_write_register(ViPipe, 0x348c, 0x00);
    ov2718_write_register(ViPipe, 0x348d, 0x01);
    ov2718_write_register(ViPipe, 0x348f, 0x01);
    ov2718_write_register(ViPipe, 0x7000, 0x1a);
    ov2718_write_register(ViPipe, 0x7001, 0xc1);
    ov2718_write_register(ViPipe, 0x7002, 0x02);
    ov2718_write_register(ViPipe, 0x7003, 0xda);
    ov2718_write_register(ViPipe, 0x7004, 0xbd);
    ov2718_write_register(ViPipe, 0x7005, 0x03);
    ov2718_write_register(ViPipe, 0x7006, 0xbd);
    ov2718_write_register(ViPipe, 0x7007, 0x06);
    ov2718_write_register(ViPipe, 0x7008, 0xe6);
    ov2718_write_register(ViPipe, 0x7009, 0xec);
    ov2718_write_register(ViPipe, 0x700a, 0x19);
    ov2718_write_register(ViPipe, 0x700b, 0xc2);
    ov2718_write_register(ViPipe, 0x700c, 0x0a);
    ov2718_write_register(ViPipe, 0x700d, 0xbc);
    ov2718_write_register(ViPipe, 0x700e, 0xf0);
    ov2718_write_register(ViPipe, 0x700f, 0xbc);
    ov2718_write_register(ViPipe, 0x7010, 0xf0);
    ov2718_write_register(ViPipe, 0x7011, 0x00);
    ov2718_write_register(ViPipe, 0x7012, 0xc0);
    ov2718_write_register(ViPipe, 0x7013, 0x0c);
    ov2718_write_register(ViPipe, 0x7014, 0xbc);
    ov2718_write_register(ViPipe, 0x7015, 0x8c);
    ov2718_write_register(ViPipe, 0x7016, 0xbc);
    ov2718_write_register(ViPipe, 0x7017, 0x14);
    ov2718_write_register(ViPipe, 0x7018, 0xda);
    ov2718_write_register(ViPipe, 0x7019, 0x76);
    ov2718_write_register(ViPipe, 0x701a, 0xb6);
    ov2718_write_register(ViPipe, 0x701b, 0xee);
    ov2718_write_register(ViPipe, 0x701c, 0xcf);
    ov2718_write_register(ViPipe, 0x701d, 0xac);
    ov2718_write_register(ViPipe, 0x701e, 0xd0);
    ov2718_write_register(ViPipe, 0x701f, 0xac);
    ov2718_write_register(ViPipe, 0x7020, 0xd1);
    ov2718_write_register(ViPipe, 0x7021, 0x50);
    ov2718_write_register(ViPipe, 0x7022, 0xac);
    ov2718_write_register(ViPipe, 0x7023, 0xd2);
    ov2718_write_register(ViPipe, 0x7024, 0xbc);
    ov2718_write_register(ViPipe, 0x7025, 0x2e);
    ov2718_write_register(ViPipe, 0x7026, 0xb4);
    ov2718_write_register(ViPipe, 0x7027, 0x00);
    ov2718_write_register(ViPipe, 0x7028, 0xdc);
    ov2718_write_register(ViPipe, 0x7029, 0xdf);
    ov2718_write_register(ViPipe, 0x702a, 0xb0);
    ov2718_write_register(ViPipe, 0x702b, 0x6e);
    ov2718_write_register(ViPipe, 0x702c, 0xbd);
    ov2718_write_register(ViPipe, 0x702d, 0x01);
    ov2718_write_register(ViPipe, 0x702e, 0xd7);
    ov2718_write_register(ViPipe, 0x702f, 0xed);
    ov2718_write_register(ViPipe, 0x7030, 0xe1);
    ov2718_write_register(ViPipe, 0x7031, 0x36);
    ov2718_write_register(ViPipe, 0x7032, 0x30);
    ov2718_write_register(ViPipe, 0x7033, 0xd3);
    ov2718_write_register(ViPipe, 0x7034, 0x2e);
    ov2718_write_register(ViPipe, 0x7035, 0x54);
    ov2718_write_register(ViPipe, 0x7036, 0x46);
    ov2718_write_register(ViPipe, 0x7037, 0xbc);
    ov2718_write_register(ViPipe, 0x7038, 0x22);
    ov2718_write_register(ViPipe, 0x7039, 0x66);
    ov2718_write_register(ViPipe, 0x703a, 0xbc);
    ov2718_write_register(ViPipe, 0x703b, 0x24);
    ov2718_write_register(ViPipe, 0x703c, 0x2c);
    ov2718_write_register(ViPipe, 0x703d, 0x28);
    ov2718_write_register(ViPipe, 0x703e, 0xbc);
    ov2718_write_register(ViPipe, 0x703f, 0x3c);
    ov2718_write_register(ViPipe, 0x7040, 0xa1);
    ov2718_write_register(ViPipe, 0x7041, 0xac);
    ov2718_write_register(ViPipe, 0x7042, 0xd8);
    ov2718_write_register(ViPipe, 0x7043, 0xd6);
    ov2718_write_register(ViPipe, 0x7044, 0xb4);
    ov2718_write_register(ViPipe, 0x7045, 0x04);
    ov2718_write_register(ViPipe, 0x7046, 0x46);
    ov2718_write_register(ViPipe, 0x7047, 0xb7);
    ov2718_write_register(ViPipe, 0x7048, 0x00);
    ov2718_write_register(ViPipe, 0x7049, 0xbe);
    ov2718_write_register(ViPipe, 0x704a, 0x08);
    ov2718_write_register(ViPipe, 0x704b, 0xc3);
    ov2718_write_register(ViPipe, 0x704c, 0xd7);
    ov2718_write_register(ViPipe, 0x704d, 0xad);
    ov2718_write_register(ViPipe, 0x704e, 0xc3);
    ov2718_write_register(ViPipe, 0x704f, 0xbc);
    ov2718_write_register(ViPipe, 0x7050, 0x19);
    ov2718_write_register(ViPipe, 0x7051, 0xc1);
    ov2718_write_register(ViPipe, 0x7052, 0x2a);
    ov2718_write_register(ViPipe, 0x7053, 0xe7);
    ov2718_write_register(ViPipe, 0x7054, 0x50);
    ov2718_write_register(ViPipe, 0x7055, 0x20);
    ov2718_write_register(ViPipe, 0x7056, 0xb8);
    ov2718_write_register(ViPipe, 0x7057, 0x02);
    ov2718_write_register(ViPipe, 0x7058, 0xbc);
    ov2718_write_register(ViPipe, 0x7059, 0x17);
    ov2718_write_register(ViPipe, 0x705a, 0xdb);
    ov2718_write_register(ViPipe, 0x705b, 0xc7);
    ov2718_write_register(ViPipe, 0x705c, 0xb8);
    ov2718_write_register(ViPipe, 0x705d, 0x00);
    ov2718_write_register(ViPipe, 0x705e, 0x28);
    ov2718_write_register(ViPipe, 0x705f, 0x54);
    ov2718_write_register(ViPipe, 0x7060, 0xb4);
    ov2718_write_register(ViPipe, 0x7061, 0x14);
    ov2718_write_register(ViPipe, 0x7062, 0xab);
    ov2718_write_register(ViPipe, 0x7063, 0xbe);
    ov2718_write_register(ViPipe, 0x7064, 0x06);
    ov2718_write_register(ViPipe, 0x7065, 0xd8);
    ov2718_write_register(ViPipe, 0x7066, 0xd6);
    ov2718_write_register(ViPipe, 0x7067, 0x00);
    ov2718_write_register(ViPipe, 0x7068, 0xb4);
    ov2718_write_register(ViPipe, 0x7069, 0xbc);
    ov2718_write_register(ViPipe, 0x706a, 0xb9);
    ov2718_write_register(ViPipe, 0x706b, 0x64);
    ov2718_write_register(ViPipe, 0x706c, 0xbc);
    ov2718_write_register(ViPipe, 0x706d, 0x16);
    ov2718_write_register(ViPipe, 0x706e, 0x62);
    ov2718_write_register(ViPipe, 0x706f, 0x05);
    ov2718_write_register(ViPipe, 0x7070, 0xee);
    ov2718_write_register(ViPipe, 0x7071, 0xe6);
    ov2718_write_register(ViPipe, 0x7072, 0xb9);
    ov2718_write_register(ViPipe, 0x7073, 0x05);
    ov2718_write_register(ViPipe, 0x7074, 0xad);
    ov2718_write_register(ViPipe, 0x7075, 0xb4);
    ov2718_write_register(ViPipe, 0x7076, 0x25);
    ov2718_write_register(ViPipe, 0x7077, 0x19);
    ov2718_write_register(ViPipe, 0x7078, 0xc1);
    ov2718_write_register(ViPipe, 0x7079, 0x3f);
    ov2718_write_register(ViPipe, 0x707a, 0xc3);
    ov2718_write_register(ViPipe, 0x707b, 0xaf);
    ov2718_write_register(ViPipe, 0x707c, 0xc0);
    ov2718_write_register(ViPipe, 0x707d, 0x41);
    ov2718_write_register(ViPipe, 0x707e, 0xc3);
    ov2718_write_register(ViPipe, 0x707f, 0xbe);
    ov2718_write_register(ViPipe, 0x7080, 0xe7);
    ov2718_write_register(ViPipe, 0x7081, 0x00);
    ov2718_write_register(ViPipe, 0x7082, 0x15);
    ov2718_write_register(ViPipe, 0x7083, 0xc2);
    ov2718_write_register(ViPipe, 0x7084, 0x45);
    ov2718_write_register(ViPipe, 0x7085, 0xc3);
    ov2718_write_register(ViPipe, 0x7086, 0xa6);
    ov2718_write_register(ViPipe, 0x7087, 0xc0);
    ov2718_write_register(ViPipe, 0x7088, 0x41);
    ov2718_write_register(ViPipe, 0x7089, 0x00);
    ov2718_write_register(ViPipe, 0x708a, 0x00);
    ov2718_write_register(ViPipe, 0x708b, 0x00);
    ov2718_write_register(ViPipe, 0x708c, 0xb9);
    ov2718_write_register(ViPipe, 0x708d, 0x64);
    ov2718_write_register(ViPipe, 0x708e, 0x29);
    ov2718_write_register(ViPipe, 0x708f, 0x00);
    ov2718_write_register(ViPipe, 0x7090, 0xb8);
    ov2718_write_register(ViPipe, 0x7091, 0x12);
    ov2718_write_register(ViPipe, 0x7092, 0xbe);
    ov2718_write_register(ViPipe, 0x7093, 0x01);
    ov2718_write_register(ViPipe, 0x7094, 0xd0);
    ov2718_write_register(ViPipe, 0x7095, 0xbc);
    ov2718_write_register(ViPipe, 0x7096, 0x01);
    ov2718_write_register(ViPipe, 0x7097, 0xac);
    ov2718_write_register(ViPipe, 0x7098, 0x37);
    ov2718_write_register(ViPipe, 0x7099, 0xd2);
    ov2718_write_register(ViPipe, 0x709a, 0xac);
    ov2718_write_register(ViPipe, 0x709b, 0xad);
    ov2718_write_register(ViPipe, 0x709c, 0x28);
    ov2718_write_register(ViPipe, 0x709d, 0x00);
    ov2718_write_register(ViPipe, 0x709e, 0xb8);
    ov2718_write_register(ViPipe, 0x709f, 0x00);
    ov2718_write_register(ViPipe, 0x70a0, 0xbc);
    ov2718_write_register(ViPipe, 0x70a1, 0x01);
    ov2718_write_register(ViPipe, 0x70a2, 0x36);
    ov2718_write_register(ViPipe, 0x70a3, 0xd3);
    ov2718_write_register(ViPipe, 0x70a4, 0x30);
    ov2718_write_register(ViPipe, 0x70a5, 0x04);
    ov2718_write_register(ViPipe, 0x70a6, 0xe0);
    ov2718_write_register(ViPipe, 0x70a7, 0xd8);
    ov2718_write_register(ViPipe, 0x70a8, 0xb4);
    ov2718_write_register(ViPipe, 0x70a9, 0xcd);
    ov2718_write_register(ViPipe, 0x70aa, 0x45);
    ov2718_write_register(ViPipe, 0x70ab, 0x00);
    ov2718_write_register(ViPipe, 0x70ac, 0xbe);
    ov2718_write_register(ViPipe, 0x70ad, 0x05);
    ov2718_write_register(ViPipe, 0x70ae, 0xbc);
    ov2718_write_register(ViPipe, 0x70af, 0x1e);
    ov2718_write_register(ViPipe, 0x70b0, 0x62);
    ov2718_write_register(ViPipe, 0x70b1, 0x07);
    ov2718_write_register(ViPipe, 0x70b2, 0xb9);
    ov2718_write_register(ViPipe, 0x70b3, 0x05);
    ov2718_write_register(ViPipe, 0x70b4, 0xad);
    ov2718_write_register(ViPipe, 0x70b5, 0xc3);
    ov2718_write_register(ViPipe, 0x70b6, 0xcd);
    ov2718_write_register(ViPipe, 0x70b7, 0x00);
    ov2718_write_register(ViPipe, 0x70b8, 0x15);
    ov2718_write_register(ViPipe, 0x70b9, 0xc2);
    ov2718_write_register(ViPipe, 0x70ba, 0x60);
    ov2718_write_register(ViPipe, 0x70bb, 0xc3);
    ov2718_write_register(ViPipe, 0x70bc, 0xc9);
    ov2718_write_register(ViPipe, 0x70bd, 0xc0);
    ov2718_write_register(ViPipe, 0x70be, 0x5c);
    ov2718_write_register(ViPipe, 0x70bf, 0x00);
    ov2718_write_register(ViPipe, 0x70c0, 0x46);
    ov2718_write_register(ViPipe, 0x70c1, 0x00);
    ov2718_write_register(ViPipe, 0x70c2, 0x00);
    ov2718_write_register(ViPipe, 0x70c3, 0xa1);
    ov2718_write_register(ViPipe, 0x70c4, 0xb9);
    ov2718_write_register(ViPipe, 0x70c5, 0x64);
    ov2718_write_register(ViPipe, 0x70c6, 0x29);
    ov2718_write_register(ViPipe, 0x70c7, 0x00);
    ov2718_write_register(ViPipe, 0x70c8, 0xb8);
    ov2718_write_register(ViPipe, 0x70c9, 0x02);
    ov2718_write_register(ViPipe, 0x70ca, 0xbe);
    ov2718_write_register(ViPipe, 0x70cb, 0x02);
    ov2718_write_register(ViPipe, 0x70cc, 0xd0);
    ov2718_write_register(ViPipe, 0x70cd, 0xdc);
    ov2718_write_register(ViPipe, 0x70ce, 0xac);
    ov2718_write_register(ViPipe, 0x70cf, 0xbc);
    ov2718_write_register(ViPipe, 0x70d0, 0x01);
    ov2718_write_register(ViPipe, 0x70d1, 0x37);
    ov2718_write_register(ViPipe, 0x70d2, 0xac);
    ov2718_write_register(ViPipe, 0x70d3, 0xd2);
    ov2718_write_register(ViPipe, 0x70d4, 0xad);
    ov2718_write_register(ViPipe, 0x70d5, 0x28);
    ov2718_write_register(ViPipe, 0x70d6, 0x00);
    ov2718_write_register(ViPipe, 0x70d7, 0xb8);
    ov2718_write_register(ViPipe, 0x70d8, 0x00);
    ov2718_write_register(ViPipe, 0x70d9, 0xbc);
    ov2718_write_register(ViPipe, 0x70da, 0x01);
    ov2718_write_register(ViPipe, 0x70db, 0x36);
    ov2718_write_register(ViPipe, 0x70dc, 0x30);
    ov2718_write_register(ViPipe, 0x70dd, 0xe0);
    ov2718_write_register(ViPipe, 0x70de, 0xd8);
    ov2718_write_register(ViPipe, 0x70df, 0xb5);
    ov2718_write_register(ViPipe, 0x70e0, 0x06);
    ov2718_write_register(ViPipe, 0x70e1, 0x45);
    ov2718_write_register(ViPipe, 0x70e2, 0xd6);
    ov2718_write_register(ViPipe, 0x70e3, 0xbe);
    ov2718_write_register(ViPipe, 0x70e4, 0x07);
    ov2718_write_register(ViPipe, 0x70e5, 0x00);
    ov2718_write_register(ViPipe, 0x70e6, 0x62);
    ov2718_write_register(ViPipe, 0x70e7, 0x07);
    ov2718_write_register(ViPipe, 0x70e8, 0xb9);
    ov2718_write_register(ViPipe, 0x70e9, 0x05);
    ov2718_write_register(ViPipe, 0x70ea, 0xad);
    ov2718_write_register(ViPipe, 0x70eb, 0xc3);
    ov2718_write_register(ViPipe, 0x70ec, 0xcd);
    ov2718_write_register(ViPipe, 0x70ed, 0x46);
    ov2718_write_register(ViPipe, 0x70ee, 0xcd);
    ov2718_write_register(ViPipe, 0x70ef, 0x07);
    ov2718_write_register(ViPipe, 0x70f0, 0xcd);
    ov2718_write_register(ViPipe, 0x70f1, 0x00);
    ov2718_write_register(ViPipe, 0x70f2, 0xe3);
    ov2718_write_register(ViPipe, 0x70f3, 0x18);
    ov2718_write_register(ViPipe, 0x70f4, 0xc2);
    ov2718_write_register(ViPipe, 0x70f5, 0xa9);
    ov2718_write_register(ViPipe, 0x70f6, 0xb9);
    ov2718_write_register(ViPipe, 0x70f7, 0x64);
    ov2718_write_register(ViPipe, 0x70f8, 0xd1);
    ov2718_write_register(ViPipe, 0x70f9, 0x50);
    ov2718_write_register(ViPipe, 0x70fa, 0xdd);
    ov2718_write_register(ViPipe, 0x70fb, 0xac);
    ov2718_write_register(ViPipe, 0x70fc, 0xcf);
    ov2718_write_register(ViPipe, 0x70fd, 0xdf);
    ov2718_write_register(ViPipe, 0x70fe, 0xb6);
    ov2718_write_register(ViPipe, 0x70ff, 0xee);
    ov2718_write_register(ViPipe, 0x7100, 0xbc);
    ov2718_write_register(ViPipe, 0x7101, 0x13);
    ov2718_write_register(ViPipe, 0x7102, 0xe1);
    ov2718_write_register(ViPipe, 0x7103, 0x36);
    ov2718_write_register(ViPipe, 0x7104, 0x30);
    ov2718_write_register(ViPipe, 0x7105, 0xd3);
    ov2718_write_register(ViPipe, 0x7106, 0x2e);
    ov2718_write_register(ViPipe, 0x7107, 0x54);
    ov2718_write_register(ViPipe, 0x7108, 0xbc);
    ov2718_write_register(ViPipe, 0x7109, 0x32);
    ov2718_write_register(ViPipe, 0x710a, 0x2c);
    ov2718_write_register(ViPipe, 0x710b, 0x50);
    ov2718_write_register(ViPipe, 0x710c, 0x20);
    ov2718_write_register(ViPipe, 0x710d, 0x04);
    ov2718_write_register(ViPipe, 0x710e, 0xb8);
    ov2718_write_register(ViPipe, 0x710f, 0x02);
    ov2718_write_register(ViPipe, 0x7110, 0xbc);
    ov2718_write_register(ViPipe, 0x7111, 0x18);
    ov2718_write_register(ViPipe, 0x7112, 0xc7);
    ov2718_write_register(ViPipe, 0x7113, 0xb8);
    ov2718_write_register(ViPipe, 0x7114, 0x00);
    ov2718_write_register(ViPipe, 0x7115, 0x28);
    ov2718_write_register(ViPipe, 0x7116, 0x54);
    ov2718_write_register(ViPipe, 0x7117, 0xb4);
    ov2718_write_register(ViPipe, 0x7118, 0xbf);
    ov2718_write_register(ViPipe, 0x7119, 0x46);
    ov2718_write_register(ViPipe, 0x711a, 0xbe);
    ov2718_write_register(ViPipe, 0x711b, 0x04);
    ov2718_write_register(ViPipe, 0x711c, 0xd6);
    ov2718_write_register(ViPipe, 0x711d, 0xd8);
    ov2718_write_register(ViPipe, 0x711e, 0xab);
    ov2718_write_register(ViPipe, 0x711f, 0x00);
    ov2718_write_register(ViPipe, 0x7120, 0x62);
    ov2718_write_register(ViPipe, 0x7121, 0x07);
    ov2718_write_register(ViPipe, 0x7122, 0xb9);
    ov2718_write_register(ViPipe, 0x7123, 0x05);
    ov2718_write_register(ViPipe, 0x7124, 0xad);
    ov2718_write_register(ViPipe, 0x7125, 0xc3);
    ov2718_write_register(ViPipe, 0x7126, 0xad);
    ov2718_write_register(ViPipe, 0x7127, 0xb9);
    ov2718_write_register(ViPipe, 0x7128, 0x64);
    ov2718_write_register(ViPipe, 0x7129, 0x29);
    ov2718_write_register(ViPipe, 0x712a, 0x00);
    ov2718_write_register(ViPipe, 0x712b, 0xb8);
    ov2718_write_register(ViPipe, 0x712c, 0x02);
    ov2718_write_register(ViPipe, 0x712d, 0xbe);
    ov2718_write_register(ViPipe, 0x712e, 0x00);
    ov2718_write_register(ViPipe, 0x712f, 0xad);
    ov2718_write_register(ViPipe, 0x7130, 0xe2);
    ov2718_write_register(ViPipe, 0x7131, 0x28);
    ov2718_write_register(ViPipe, 0x7132, 0x00);
    ov2718_write_register(ViPipe, 0x7133, 0xb8);
    ov2718_write_register(ViPipe, 0x7134, 0x00);
    ov2718_write_register(ViPipe, 0x7135, 0xe6);
    ov2718_write_register(ViPipe, 0x7136, 0xbd);
    ov2718_write_register(ViPipe, 0x7137, 0x03);
    ov2718_write_register(ViPipe, 0x7138, 0xec);
    ov2718_write_register(ViPipe, 0x7139, 0xe0);
    ov2718_write_register(ViPipe, 0x713a, 0xd8);
    ov2718_write_register(ViPipe, 0x713b, 0xb4);
    ov2718_write_register(ViPipe, 0x713c, 0xcd);
    ov2718_write_register(ViPipe, 0x713d, 0x45);
    ov2718_write_register(ViPipe, 0x713e, 0xbe);
    ov2718_write_register(ViPipe, 0x713f, 0x03);
    ov2718_write_register(ViPipe, 0x7140, 0x00);
    ov2718_write_register(ViPipe, 0x7141, 0x30);
    ov2718_write_register(ViPipe, 0x7142, 0xbc);
    ov2718_write_register(ViPipe, 0x7143, 0x1c);
    ov2718_write_register(ViPipe, 0x7144, 0x62);
    ov2718_write_register(ViPipe, 0x7145, 0x07);
    ov2718_write_register(ViPipe, 0x7146, 0xb9);
    ov2718_write_register(ViPipe, 0x7147, 0x05);
    ov2718_write_register(ViPipe, 0x7148, 0xad);
    ov2718_write_register(ViPipe, 0x7149, 0xc3);
    ov2718_write_register(ViPipe, 0x714a, 0xcd);
    ov2718_write_register(ViPipe, 0x714b, 0x42);
    ov2718_write_register(ViPipe, 0x714c, 0xe4);
    ov2718_write_register(ViPipe, 0x714d, 0xcd);
    ov2718_write_register(ViPipe, 0x714e, 0x07);
    ov2718_write_register(ViPipe, 0x714f, 0xcd);
    ov2718_write_register(ViPipe, 0x7150, 0x00);
    ov2718_write_register(ViPipe, 0x7151, 0x00);
    ov2718_write_register(ViPipe, 0x7152, 0x17);
    ov2718_write_register(ViPipe, 0x7153, 0xc2);
    ov2718_write_register(ViPipe, 0x7154, 0xc2);
    ov2718_write_register(ViPipe, 0x7155, 0xde);
    ov2718_write_register(ViPipe, 0x7156, 0xcf);
    ov2718_write_register(ViPipe, 0x7157, 0xdf);
    ov2718_write_register(ViPipe, 0x7158, 0xac);
    ov2718_write_register(ViPipe, 0x7159, 0xd1);
    ov2718_write_register(ViPipe, 0x715a, 0x44);
    ov2718_write_register(ViPipe, 0x715b, 0xac);
    ov2718_write_register(ViPipe, 0x715c, 0xb9);
    ov2718_write_register(ViPipe, 0x715d, 0x76);
    ov2718_write_register(ViPipe, 0x715e, 0xb8);
    ov2718_write_register(ViPipe, 0x715f, 0x08);
    ov2718_write_register(ViPipe, 0x7160, 0xb6);
    ov2718_write_register(ViPipe, 0x7161, 0xfe);
    ov2718_write_register(ViPipe, 0x7162, 0xb4);
    ov2718_write_register(ViPipe, 0x7163, 0xbf);
    ov2718_write_register(ViPipe, 0x7164, 0xd6);
    ov2718_write_register(ViPipe, 0x7165, 0xd8);
    ov2718_write_register(ViPipe, 0x7166, 0xab);
    ov2718_write_register(ViPipe, 0x7167, 0x00);
    ov2718_write_register(ViPipe, 0x7168, 0xe1);
    ov2718_write_register(ViPipe, 0x7169, 0x36);
    ov2718_write_register(ViPipe, 0x716a, 0x30);
    ov2718_write_register(ViPipe, 0x716b, 0xd3);
    ov2718_write_register(ViPipe, 0x716c, 0xbc);
    ov2718_write_register(ViPipe, 0x716d, 0x29);
    ov2718_write_register(ViPipe, 0x716e, 0xb4);
    ov2718_write_register(ViPipe, 0x716f, 0x1d);
    ov2718_write_register(ViPipe, 0x7170, 0xaa);
    ov2718_write_register(ViPipe, 0x7171, 0xbd);
    ov2718_write_register(ViPipe, 0x7172, 0x01);
    ov2718_write_register(ViPipe, 0x7173, 0xb8);
    ov2718_write_register(ViPipe, 0x7174, 0x0c);
    ov2718_write_register(ViPipe, 0x7175, 0x45);
    ov2718_write_register(ViPipe, 0x7176, 0xe6);
    ov2718_write_register(ViPipe, 0x7177, 0xbd);
    ov2718_write_register(ViPipe, 0x7178, 0x03);
    ov2718_write_register(ViPipe, 0x7179, 0xec);
    ov2718_write_register(ViPipe, 0x717a, 0xbc);
    ov2718_write_register(ViPipe, 0x717b, 0x3d);
    ov2718_write_register(ViPipe, 0x717c, 0xc3);
    ov2718_write_register(ViPipe, 0x717d, 0xcd);
    ov2718_write_register(ViPipe, 0x717e, 0x42);
    ov2718_write_register(ViPipe, 0x717f, 0xb8);
    ov2718_write_register(ViPipe, 0x7180, 0x00);
    ov2718_write_register(ViPipe, 0x7181, 0xe4);
    ov2718_write_register(ViPipe, 0x7182, 0xd5);
    ov2718_write_register(ViPipe, 0x7183, 0x00);
    ov2718_write_register(ViPipe, 0x7184, 0xb6);
    ov2718_write_register(ViPipe, 0x7185, 0x00);
    ov2718_write_register(ViPipe, 0x7186, 0xbd);
    ov2718_write_register(ViPipe, 0x7187, 0x03);
    ov2718_write_register(ViPipe, 0x7188, 0xb5);
    ov2718_write_register(ViPipe, 0x7189, 0x4b);
    ov2718_write_register(ViPipe, 0x718a, 0x40);
    ov2718_write_register(ViPipe, 0x718b, 0x58);
    ov2718_write_register(ViPipe, 0x718c, 0x6a);
    ov2718_write_register(ViPipe, 0x718d, 0xdd);
    ov2718_write_register(ViPipe, 0x718e, 0x19);
    ov2718_write_register(ViPipe, 0x718f, 0xc1);
    ov2718_write_register(ViPipe, 0x7190, 0xc9);
    ov2718_write_register(ViPipe, 0x7191, 0xe8);
    ov2718_write_register(ViPipe, 0x7192, 0xbc);
    ov2718_write_register(ViPipe, 0x7193, 0x19);
    ov2718_write_register(ViPipe, 0x7194, 0xb9);
    ov2718_write_register(ViPipe, 0x7195, 0xf6);
    ov2718_write_register(ViPipe, 0x7196, 0x14);
    ov2718_write_register(ViPipe, 0x7197, 0xc1);
    ov2718_write_register(ViPipe, 0x7198, 0xd1);
    ov2718_write_register(ViPipe, 0x7199, 0xd1);
    ov2718_write_register(ViPipe, 0x719a, 0xac);
    ov2718_write_register(ViPipe, 0x719b, 0x37);
    ov2718_write_register(ViPipe, 0x719c, 0xbc);
    ov2718_write_register(ViPipe, 0x719d, 0x35);
    ov2718_write_register(ViPipe, 0x719e, 0x36);
    ov2718_write_register(ViPipe, 0x719f, 0x30);
    ov2718_write_register(ViPipe, 0x71a0, 0xe1);
    ov2718_write_register(ViPipe, 0x71a1, 0xd3);
    ov2718_write_register(ViPipe, 0x71a2, 0x7a);
    ov2718_write_register(ViPipe, 0x71a3, 0xb6);
    ov2718_write_register(ViPipe, 0x71a4, 0x0c);
    ov2718_write_register(ViPipe, 0x71a5, 0xff);
    ov2718_write_register(ViPipe, 0x71a6, 0xb4);
    ov2718_write_register(ViPipe, 0x71a7, 0xbc);
    ov2718_write_register(ViPipe, 0x71a8, 0xd9);
    ov2718_write_register(ViPipe, 0x71a9, 0x00);
    ov2718_write_register(ViPipe, 0x71aa, 0x56);
    ov2718_write_register(ViPipe, 0x71ab, 0xc0);
    ov2718_write_register(ViPipe, 0x71ac, 0xda);
    ov2718_write_register(ViPipe, 0x71ad, 0xb4);
    ov2718_write_register(ViPipe, 0x71ae, 0x1d);
    ov2718_write_register(ViPipe, 0x71af, 0x56);
    ov2718_write_register(ViPipe, 0x71b0, 0xaa);
    ov2718_write_register(ViPipe, 0x71b1, 0xbc);
    ov2718_write_register(ViPipe, 0x71b2, 0x08);
    ov2718_write_register(ViPipe, 0x71b3, 0x00);
    ov2718_write_register(ViPipe, 0x71b4, 0x57);
    ov2718_write_register(ViPipe, 0x71b5, 0xe8);
    ov2718_write_register(ViPipe, 0x71b6, 0xb5);
    ov2718_write_register(ViPipe, 0x71b7, 0x48);
    ov2718_write_register(ViPipe, 0x71b8, 0x00);
    ov2718_write_register(ViPipe, 0x71b9, 0x54);
    ov2718_write_register(ViPipe, 0x71ba, 0xe7);
    ov2718_write_register(ViPipe, 0x71bb, 0xc8);
    ov2718_write_register(ViPipe, 0x71bc, 0xb4);
    ov2718_write_register(ViPipe, 0x71bd, 0x1d);
    ov2718_write_register(ViPipe, 0x71be, 0x56);
    ov2718_write_register(ViPipe, 0x71bf, 0xaa);
    ov2718_write_register(ViPipe, 0x71c0, 0xbc);
    ov2718_write_register(ViPipe, 0x71c1, 0x08);
    ov2718_write_register(ViPipe, 0x71c2, 0x57);
    ov2718_write_register(ViPipe, 0x71c3, 0x00);
    ov2718_write_register(ViPipe, 0x71c4, 0xb5);
    ov2718_write_register(ViPipe, 0x71c5, 0x48);
    ov2718_write_register(ViPipe, 0x71c6, 0x00);
    ov2718_write_register(ViPipe, 0x71c7, 0x54);
    ov2718_write_register(ViPipe, 0x71c8, 0xc8);
    ov2718_write_register(ViPipe, 0x71c9, 0xb5);
    ov2718_write_register(ViPipe, 0x71ca, 0x14);
    ov2718_write_register(ViPipe, 0x71cb, 0xd9);
    ov2718_write_register(ViPipe, 0x71cc, 0x00);
    ov2718_write_register(ViPipe, 0x71cd, 0x56);
    ov2718_write_register(ViPipe, 0x71ce, 0x08);
    ov2718_write_register(ViPipe, 0x71cf, 0x57);
    ov2718_write_register(ViPipe, 0x71d0, 0xe8);
    ov2718_write_register(ViPipe, 0x71d1, 0xb4);
    ov2718_write_register(ViPipe, 0x71d2, 0x44);
    ov2718_write_register(ViPipe, 0x71d3, 0x00);
    ov2718_write_register(ViPipe, 0x71d4, 0x54);
    ov2718_write_register(ViPipe, 0x71d5, 0xe7);
    ov2718_write_register(ViPipe, 0x71d6, 0xc8);
    ov2718_write_register(ViPipe, 0x71d7, 0xab);
    ov2718_write_register(ViPipe, 0x71d8, 0x00);
    ov2718_write_register(ViPipe, 0x71d9, 0x66);
    ov2718_write_register(ViPipe, 0x71da, 0x62);
    ov2718_write_register(ViPipe, 0x71db, 0x06);
    ov2718_write_register(ViPipe, 0x71dc, 0x74);
    ov2718_write_register(ViPipe, 0x71dd, 0xb9);
    ov2718_write_register(ViPipe, 0x71de, 0x05);
    ov2718_write_register(ViPipe, 0x71df, 0xb7);
    ov2718_write_register(ViPipe, 0x71e0, 0x10);
    ov2718_write_register(ViPipe, 0x71e1, 0x0e);
    ov2718_write_register(ViPipe, 0x71e2, 0xb7);
    ov2718_write_register(ViPipe, 0x71e3, 0x04);
    ov2718_write_register(ViPipe, 0x71e4, 0xc8);
    ov2718_write_register(ViPipe, 0x7600, 0x04);
    ov2718_write_register(ViPipe, 0x7601, 0x80);
    ov2718_write_register(ViPipe, 0x7602, 0x07);
    ov2718_write_register(ViPipe, 0x7603, 0x44);
    ov2718_write_register(ViPipe, 0x7604, 0x05);
    ov2718_write_register(ViPipe, 0x7605, 0x33);
    ov2718_write_register(ViPipe, 0x7606, 0x0f);
    ov2718_write_register(ViPipe, 0x7607, 0x00);
    ov2718_write_register(ViPipe, 0x7608, 0x07);
    ov2718_write_register(ViPipe, 0x7609, 0x40);
    ov2718_write_register(ViPipe, 0x760a, 0x04);
    ov2718_write_register(ViPipe, 0x760b, 0xe5);
    ov2718_write_register(ViPipe, 0x760c, 0x06);
    ov2718_write_register(ViPipe, 0x760d, 0x50);
    ov2718_write_register(ViPipe, 0x760e, 0x04);
    ov2718_write_register(ViPipe, 0x760f, 0xe4);
    ov2718_write_register(ViPipe, 0x7610, 0x00);
    ov2718_write_register(ViPipe, 0x7611, 0x00);
    ov2718_write_register(ViPipe, 0x7612, 0x06);
    ov2718_write_register(ViPipe, 0x7613, 0x5c);
    ov2718_write_register(ViPipe, 0x7614, 0x00);
    ov2718_write_register(ViPipe, 0x7615, 0x0f);
    ov2718_write_register(ViPipe, 0x7616, 0x06);
    ov2718_write_register(ViPipe, 0x7617, 0x1c);
    ov2718_write_register(ViPipe, 0x7618, 0x00);
    ov2718_write_register(ViPipe, 0x7619, 0x02);
    ov2718_write_register(ViPipe, 0x761a, 0x06);
    ov2718_write_register(ViPipe, 0x761b, 0xa0);
    ov2718_write_register(ViPipe, 0x761c, 0x00);
    ov2718_write_register(ViPipe, 0x761d, 0x01);
    ov2718_write_register(ViPipe, 0x761e, 0x06);
    ov2718_write_register(ViPipe, 0x761f, 0xac);
    ov2718_write_register(ViPipe, 0x7620, 0x00);
    ov2718_write_register(ViPipe, 0x7621, 0x0f);
    ov2718_write_register(ViPipe, 0x7622, 0x05);
    ov2718_write_register(ViPipe, 0x7623, 0x30);
    ov2718_write_register(ViPipe, 0x7624, 0x07);
    ov2718_write_register(ViPipe, 0x7625, 0x00);
    ov2718_write_register(ViPipe, 0x7626, 0x0f);
    ov2718_write_register(ViPipe, 0x7627, 0x00);
    ov2718_write_register(ViPipe, 0x7628, 0x04);
    ov2718_write_register(ViPipe, 0x7629, 0xe5);
    ov2718_write_register(ViPipe, 0x762a, 0x05);
    ov2718_write_register(ViPipe, 0x762b, 0x33);
    ov2718_write_register(ViPipe, 0x762c, 0x06);
    ov2718_write_register(ViPipe, 0x762d, 0x50);
    ov2718_write_register(ViPipe, 0x762e, 0x00);
    ov2718_write_register(ViPipe, 0x762f, 0x01);
    ov2718_write_register(ViPipe, 0x7630, 0x06);
    ov2718_write_register(ViPipe, 0x7631, 0x5c);
    ov2718_write_register(ViPipe, 0x7632, 0x04);
    ov2718_write_register(ViPipe, 0x7633, 0xe4);
    ov2718_write_register(ViPipe, 0x7634, 0x00);
    ov2718_write_register(ViPipe, 0x7635, 0x0e);
    ov2718_write_register(ViPipe, 0x7636, 0x05);
    ov2718_write_register(ViPipe, 0x7637, 0x30);
    ov2718_write_register(ViPipe, 0x7638, 0x0f);
    ov2718_write_register(ViPipe, 0x7639, 0x00);
    ov2718_write_register(ViPipe, 0x763a, 0x06);
    ov2718_write_register(ViPipe, 0x763b, 0x24);
    ov2718_write_register(ViPipe, 0x763c, 0x00);
    ov2718_write_register(ViPipe, 0x763d, 0x03);
    ov2718_write_register(ViPipe, 0x763e, 0x05);
    ov2718_write_register(ViPipe, 0x763f, 0x33);
    ov2718_write_register(ViPipe, 0x7640, 0x07);
    ov2718_write_register(ViPipe, 0x7641, 0x02);
    ov2718_write_register(ViPipe, 0x7642, 0x06);
    ov2718_write_register(ViPipe, 0x7643, 0x24);
    ov2718_write_register(ViPipe, 0x7644, 0x00);
    ov2718_write_register(ViPipe, 0x7645, 0x01);
    ov2718_write_register(ViPipe, 0x7646, 0x06);
    ov2718_write_register(ViPipe, 0x7647, 0x20);
    ov2718_write_register(ViPipe, 0x7648, 0x0f);
    ov2718_write_register(ViPipe, 0x7649, 0x00);
    ov2718_write_register(ViPipe, 0x764a, 0x06);
    ov2718_write_register(ViPipe, 0x764b, 0x14);
    ov2718_write_register(ViPipe, 0x764c, 0x00);
    ov2718_write_register(ViPipe, 0x764d, 0x03);
    ov2718_write_register(ViPipe, 0x764e, 0x05);
    ov2718_write_register(ViPipe, 0x764f, 0x33);
    ov2718_write_register(ViPipe, 0x7650, 0x07);
    ov2718_write_register(ViPipe, 0x7651, 0x02);
    ov2718_write_register(ViPipe, 0x7652, 0x06);
    ov2718_write_register(ViPipe, 0x7653, 0x14);
    ov2718_write_register(ViPipe, 0x7654, 0x00);
    ov2718_write_register(ViPipe, 0x7655, 0x01);
    ov2718_write_register(ViPipe, 0x7656, 0x06);
    ov2718_write_register(ViPipe, 0x7657, 0x10);
    ov2718_write_register(ViPipe, 0x7658, 0x0f);
    ov2718_write_register(ViPipe, 0x7659, 0x00);
    ov2718_write_register(ViPipe, 0x765a, 0x06);
    ov2718_write_register(ViPipe, 0x765b, 0x10);
    ov2718_write_register(ViPipe, 0x765c, 0x0f);
    ov2718_write_register(ViPipe, 0x765d, 0x00);
    ov2718_write_register(ViPipe, 0x765e, 0x06);
    ov2718_write_register(ViPipe, 0x765f, 0x20);
    ov2718_write_register(ViPipe, 0x7660, 0x0f);
    ov2718_write_register(ViPipe, 0x7661, 0x00);
    ov2718_write_register(ViPipe, 0x7662, 0x00);
    ov2718_write_register(ViPipe, 0x7663, 0x00);
    ov2718_write_register(ViPipe, 0x7664, 0x00);
    ov2718_write_register(ViPipe, 0x7665, 0x02);
    ov2718_write_register(ViPipe, 0x7666, 0x04);
    ov2718_write_register(ViPipe, 0x7667, 0xe5);
    ov2718_write_register(ViPipe, 0x7668, 0x04);
    ov2718_write_register(ViPipe, 0x7669, 0xe4);
    ov2718_write_register(ViPipe, 0x766a, 0x0f);
    ov2718_write_register(ViPipe, 0x766b, 0x00);
    ov2718_write_register(ViPipe, 0x766c, 0x00);
    ov2718_write_register(ViPipe, 0x766d, 0x00);
    ov2718_write_register(ViPipe, 0x766e, 0x00);
    ov2718_write_register(ViPipe, 0x766f, 0x02);
    ov2718_write_register(ViPipe, 0x7670, 0x04);
    ov2718_write_register(ViPipe, 0x7671, 0xe5);
    ov2718_write_register(ViPipe, 0x7672, 0x04);
    ov2718_write_register(ViPipe, 0x7673, 0xe4);
    ov2718_write_register(ViPipe, 0x7674, 0x0f);
    ov2718_write_register(ViPipe, 0x7675, 0x00);
    ov2718_write_register(ViPipe, 0x7676, 0x00);
    ov2718_write_register(ViPipe, 0x7677, 0x02);
    ov2718_write_register(ViPipe, 0x7678, 0x04);
    ov2718_write_register(ViPipe, 0x7679, 0xe4);
    ov2718_write_register(ViPipe, 0x767a, 0x00);
    ov2718_write_register(ViPipe, 0x767b, 0x02);
    ov2718_write_register(ViPipe, 0x767c, 0x04);
    ov2718_write_register(ViPipe, 0x767d, 0xc4);
    ov2718_write_register(ViPipe, 0x767e, 0x00);
    ov2718_write_register(ViPipe, 0x767f, 0x04);
    ov2718_write_register(ViPipe, 0x7680, 0x04);
    ov2718_write_register(ViPipe, 0x7681, 0xc4);
    ov2718_write_register(ViPipe, 0x7682, 0x05);
    ov2718_write_register(ViPipe, 0x7683, 0x83);
    ov2718_write_register(ViPipe, 0x7684, 0x07);
    ov2718_write_register(ViPipe, 0x7685, 0x02);
    ov2718_write_register(ViPipe, 0x7686, 0x0f);
    ov2718_write_register(ViPipe, 0x7687, 0x00);
    ov2718_write_register(ViPipe, 0x7688, 0x00);
    ov2718_write_register(ViPipe, 0x7689, 0x02);
    ov2718_write_register(ViPipe, 0x768a, 0x04);
    ov2718_write_register(ViPipe, 0x768b, 0xe4);
    ov2718_write_register(ViPipe, 0x768c, 0x00);
    ov2718_write_register(ViPipe, 0x768d, 0x02);
    ov2718_write_register(ViPipe, 0x768e, 0x04);
    ov2718_write_register(ViPipe, 0x768f, 0xc4);
    ov2718_write_register(ViPipe, 0x7690, 0x00);
    ov2718_write_register(ViPipe, 0x7691, 0x04);
    ov2718_write_register(ViPipe, 0x7692, 0x04);
    ov2718_write_register(ViPipe, 0x7693, 0xc4);
    ov2718_write_register(ViPipe, 0x7694, 0x05);
    ov2718_write_register(ViPipe, 0x7695, 0x83);
    ov2718_write_register(ViPipe, 0x7696, 0x07);
    ov2718_write_register(ViPipe, 0x7697, 0x02);
    ov2718_write_register(ViPipe, 0x7698, 0x03);
    ov2718_write_register(ViPipe, 0x7699, 0x0b);
    ov2718_write_register(ViPipe, 0x769a, 0x05);
    ov2718_write_register(ViPipe, 0x769b, 0x83);
    ov2718_write_register(ViPipe, 0x769c, 0x00);
    ov2718_write_register(ViPipe, 0x769d, 0x08);
    ov2718_write_register(ViPipe, 0x769e, 0x05);
    ov2718_write_register(ViPipe, 0x769f, 0x03);
    ov2718_write_register(ViPipe, 0x76a0, 0x05);
    ov2718_write_register(ViPipe, 0x76a1, 0x32);
    ov2718_write_register(ViPipe, 0x76a2, 0x00);
    ov2718_write_register(ViPipe, 0x76a3, 0x00);
    ov2718_write_register(ViPipe, 0x76a4, 0x05);
    ov2718_write_register(ViPipe, 0x76a5, 0x70);
    ov2718_write_register(ViPipe, 0x76a6, 0x00);
    ov2718_write_register(ViPipe, 0x76a7, 0x01);
    ov2718_write_register(ViPipe, 0x76a8, 0x05);
    ov2718_write_register(ViPipe, 0x76a9, 0x74);
    ov2718_write_register(ViPipe, 0x76aa, 0x03);
    ov2718_write_register(ViPipe, 0x76ab, 0x9a);
    ov2718_write_register(ViPipe, 0x76ac, 0x05);
    ov2718_write_register(ViPipe, 0x76ad, 0x83);
    ov2718_write_register(ViPipe, 0x76ae, 0x00);
    ov2718_write_register(ViPipe, 0x76af, 0x05);
    ov2718_write_register(ViPipe, 0x76b0, 0x05);
    ov2718_write_register(ViPipe, 0x76b1, 0x03);
    ov2718_write_register(ViPipe, 0x76b2, 0x05);
    ov2718_write_register(ViPipe, 0x76b3, 0x32);
    ov2718_write_register(ViPipe, 0x76b4, 0x00);
    ov2718_write_register(ViPipe, 0x76b5, 0x00);
    ov2718_write_register(ViPipe, 0x76b6, 0x05);
    ov2718_write_register(ViPipe, 0x76b7, 0x70);
    ov2718_write_register(ViPipe, 0x76b8, 0x00);
    ov2718_write_register(ViPipe, 0x76b9, 0x01);
    ov2718_write_register(ViPipe, 0x76ba, 0x05);
    ov2718_write_register(ViPipe, 0x76bb, 0x74);
    ov2718_write_register(ViPipe, 0x76bc, 0x03);
    ov2718_write_register(ViPipe, 0x76bd, 0x99);
    ov2718_write_register(ViPipe, 0x76be, 0x05);
    ov2718_write_register(ViPipe, 0x76bf, 0x83);
    ov2718_write_register(ViPipe, 0x76c0, 0x00);
    ov2718_write_register(ViPipe, 0x76c1, 0x03);
    ov2718_write_register(ViPipe, 0x76c2, 0x05);
    ov2718_write_register(ViPipe, 0x76c3, 0x03);
    ov2718_write_register(ViPipe, 0x76c4, 0x05);
    ov2718_write_register(ViPipe, 0x76c5, 0x32);
    ov2718_write_register(ViPipe, 0x76c6, 0x00);
    ov2718_write_register(ViPipe, 0x76c7, 0x00);
    ov2718_write_register(ViPipe, 0x76c8, 0x05);
    ov2718_write_register(ViPipe, 0x76c9, 0x70);
    ov2718_write_register(ViPipe, 0x76ca, 0x00);
    ov2718_write_register(ViPipe, 0x76cb, 0x01);
    ov2718_write_register(ViPipe, 0x76cc, 0x05);
    ov2718_write_register(ViPipe, 0x76cd, 0x74);
    ov2718_write_register(ViPipe, 0x76ce, 0x03);
    ov2718_write_register(ViPipe, 0x76cf, 0x98);
    ov2718_write_register(ViPipe, 0x76d0, 0x05);
    ov2718_write_register(ViPipe, 0x76d1, 0x83);
    ov2718_write_register(ViPipe, 0x76d2, 0x00);
    ov2718_write_register(ViPipe, 0x76d3, 0x01);
    ov2718_write_register(ViPipe, 0x76d4, 0x05);
    ov2718_write_register(ViPipe, 0x76d5, 0x03);
    ov2718_write_register(ViPipe, 0x76d6, 0x05);
    ov2718_write_register(ViPipe, 0x76d7, 0x32);
    ov2718_write_register(ViPipe, 0x76d8, 0x00);
    ov2718_write_register(ViPipe, 0x76d9, 0x00);
    ov2718_write_register(ViPipe, 0x76da, 0x05);
    ov2718_write_register(ViPipe, 0x76db, 0x70);
    ov2718_write_register(ViPipe, 0x76dc, 0x00);
    ov2718_write_register(ViPipe, 0x76dd, 0x01);
    ov2718_write_register(ViPipe, 0x76de, 0x05);
    ov2718_write_register(ViPipe, 0x76df, 0x74);
    ov2718_write_register(ViPipe, 0x76e0, 0x03);
    ov2718_write_register(ViPipe, 0x76e1, 0x97);
    ov2718_write_register(ViPipe, 0x76e2, 0x05);
    ov2718_write_register(ViPipe, 0x76e3, 0x83);
    ov2718_write_register(ViPipe, 0x76e4, 0x00);
    ov2718_write_register(ViPipe, 0x76e5, 0x01);
    ov2718_write_register(ViPipe, 0x76e6, 0x05);
    ov2718_write_register(ViPipe, 0x76e7, 0x03);
    ov2718_write_register(ViPipe, 0x76e8, 0x05);
    ov2718_write_register(ViPipe, 0x76e9, 0x32);
    ov2718_write_register(ViPipe, 0x76ea, 0x00);
    ov2718_write_register(ViPipe, 0x76eb, 0x00);
    ov2718_write_register(ViPipe, 0x76ec, 0x05);
    ov2718_write_register(ViPipe, 0x76ed, 0x70);
    ov2718_write_register(ViPipe, 0x76ee, 0x00);
    ov2718_write_register(ViPipe, 0x76ef, 0x01);
    ov2718_write_register(ViPipe, 0x76f0, 0x05);
    ov2718_write_register(ViPipe, 0x76f1, 0x74);
    ov2718_write_register(ViPipe, 0x76f2, 0x03);
    ov2718_write_register(ViPipe, 0x76f3, 0x96);
    ov2718_write_register(ViPipe, 0x76f4, 0x05);
    ov2718_write_register(ViPipe, 0x76f5, 0x83);
    ov2718_write_register(ViPipe, 0x76f6, 0x00);
    ov2718_write_register(ViPipe, 0x76f7, 0x01);
    ov2718_write_register(ViPipe, 0x76f8, 0x05);
    ov2718_write_register(ViPipe, 0x76f9, 0x03);
    ov2718_write_register(ViPipe, 0x76fa, 0x05);
    ov2718_write_register(ViPipe, 0x76fb, 0x32);
    ov2718_write_register(ViPipe, 0x76fc, 0x00);
    ov2718_write_register(ViPipe, 0x76fd, 0x00);
    ov2718_write_register(ViPipe, 0x76fe, 0x05);
    ov2718_write_register(ViPipe, 0x76ff, 0x70);
    ov2718_write_register(ViPipe, 0x7700, 0x00);
    ov2718_write_register(ViPipe, 0x7701, 0x01);
    ov2718_write_register(ViPipe, 0x7702, 0x05);
    ov2718_write_register(ViPipe, 0x7703, 0x74);
    ov2718_write_register(ViPipe, 0x7704, 0x03);
    ov2718_write_register(ViPipe, 0x7705, 0x95);
    ov2718_write_register(ViPipe, 0x7706, 0x05);
    ov2718_write_register(ViPipe, 0x7707, 0x83);
    ov2718_write_register(ViPipe, 0x7708, 0x00);
    ov2718_write_register(ViPipe, 0x7709, 0x01);
    ov2718_write_register(ViPipe, 0x770a, 0x05);
    ov2718_write_register(ViPipe, 0x770b, 0x03);
    ov2718_write_register(ViPipe, 0x770c, 0x05);
    ov2718_write_register(ViPipe, 0x770d, 0x32);
    ov2718_write_register(ViPipe, 0x770e, 0x00);
    ov2718_write_register(ViPipe, 0x770f, 0x00);
    ov2718_write_register(ViPipe, 0x7710, 0x05);
    ov2718_write_register(ViPipe, 0x7711, 0x70);
    ov2718_write_register(ViPipe, 0x7712, 0x00);
    ov2718_write_register(ViPipe, 0x7713, 0x01);
    ov2718_write_register(ViPipe, 0x7714, 0x05);
    ov2718_write_register(ViPipe, 0x7715, 0x74);
    ov2718_write_register(ViPipe, 0x7716, 0x03);
    ov2718_write_register(ViPipe, 0x7717, 0x94);
    ov2718_write_register(ViPipe, 0x7718, 0x05);
    ov2718_write_register(ViPipe, 0x7719, 0x83);
    ov2718_write_register(ViPipe, 0x771a, 0x00);
    ov2718_write_register(ViPipe, 0x771b, 0x03);
    ov2718_write_register(ViPipe, 0x771c, 0x05);
    ov2718_write_register(ViPipe, 0x771d, 0x03);
    ov2718_write_register(ViPipe, 0x771e, 0x05);
    ov2718_write_register(ViPipe, 0x771f, 0x32);
    ov2718_write_register(ViPipe, 0x7720, 0x00);
    ov2718_write_register(ViPipe, 0x7721, 0x00);
    ov2718_write_register(ViPipe, 0x7722, 0x05);
    ov2718_write_register(ViPipe, 0x7723, 0x70);
    ov2718_write_register(ViPipe, 0x7724, 0x00);
    ov2718_write_register(ViPipe, 0x7725, 0x01);
    ov2718_write_register(ViPipe, 0x7726, 0x05);
    ov2718_write_register(ViPipe, 0x7727, 0x74);
    ov2718_write_register(ViPipe, 0x7728, 0x03);
    ov2718_write_register(ViPipe, 0x7729, 0x93);
    ov2718_write_register(ViPipe, 0x772a, 0x05);
    ov2718_write_register(ViPipe, 0x772b, 0x83);
    ov2718_write_register(ViPipe, 0x772c, 0x00);
    ov2718_write_register(ViPipe, 0x772d, 0x02);
    ov2718_write_register(ViPipe, 0x772e, 0x05);
    ov2718_write_register(ViPipe, 0x772f, 0x03);
    ov2718_write_register(ViPipe, 0x7730, 0x05);
    ov2718_write_register(ViPipe, 0x7731, 0x32);
    ov2718_write_register(ViPipe, 0x7732, 0x00);
    ov2718_write_register(ViPipe, 0x7733, 0x00);
    ov2718_write_register(ViPipe, 0x7734, 0x05);
    ov2718_write_register(ViPipe, 0x7735, 0x70);
    ov2718_write_register(ViPipe, 0x7736, 0x00);
    ov2718_write_register(ViPipe, 0x7737, 0x01);
    ov2718_write_register(ViPipe, 0x7738, 0x05);
    ov2718_write_register(ViPipe, 0x7739, 0x74);
    ov2718_write_register(ViPipe, 0x773a, 0x03);
    ov2718_write_register(ViPipe, 0x773b, 0x92);
    ov2718_write_register(ViPipe, 0x773c, 0x05);
    ov2718_write_register(ViPipe, 0x773d, 0x83);
    ov2718_write_register(ViPipe, 0x773e, 0x00);
    ov2718_write_register(ViPipe, 0x773f, 0x01);
    ov2718_write_register(ViPipe, 0x7740, 0x05);
    ov2718_write_register(ViPipe, 0x7741, 0x03);
    ov2718_write_register(ViPipe, 0x7742, 0x05);
    ov2718_write_register(ViPipe, 0x7743, 0x32);
    ov2718_write_register(ViPipe, 0x7744, 0x00);
    ov2718_write_register(ViPipe, 0x7745, 0x00);
    ov2718_write_register(ViPipe, 0x7746, 0x05);
    ov2718_write_register(ViPipe, 0x7747, 0x70);
    ov2718_write_register(ViPipe, 0x7748, 0x00);
    ov2718_write_register(ViPipe, 0x7749, 0x01);
    ov2718_write_register(ViPipe, 0x774a, 0x05);
    ov2718_write_register(ViPipe, 0x774b, 0x74);
    ov2718_write_register(ViPipe, 0x774c, 0x03);
    ov2718_write_register(ViPipe, 0x774d, 0x91);
    ov2718_write_register(ViPipe, 0x774e, 0x05);
    ov2718_write_register(ViPipe, 0x774f, 0x83);
    ov2718_write_register(ViPipe, 0x7750, 0x00);
    ov2718_write_register(ViPipe, 0x7751, 0x01);
    ov2718_write_register(ViPipe, 0x7752, 0x05);
    ov2718_write_register(ViPipe, 0x7753, 0x03);
    ov2718_write_register(ViPipe, 0x7754, 0x05);
    ov2718_write_register(ViPipe, 0x7755, 0x32);
    ov2718_write_register(ViPipe, 0x7756, 0x00);
    ov2718_write_register(ViPipe, 0x7757, 0x00);
    ov2718_write_register(ViPipe, 0x7758, 0x05);
    ov2718_write_register(ViPipe, 0x7759, 0x70);
    ov2718_write_register(ViPipe, 0x775a, 0x00);
    ov2718_write_register(ViPipe, 0x775b, 0x01);
    ov2718_write_register(ViPipe, 0x775c, 0x05);
    ov2718_write_register(ViPipe, 0x775d, 0x74);
    ov2718_write_register(ViPipe, 0x775e, 0x03);
    ov2718_write_register(ViPipe, 0x775f, 0x90);
    ov2718_write_register(ViPipe, 0x7760, 0x05);
    ov2718_write_register(ViPipe, 0x7761, 0x83);
    ov2718_write_register(ViPipe, 0x7762, 0x00);
    ov2718_write_register(ViPipe, 0x7763, 0x01);
    ov2718_write_register(ViPipe, 0x7764, 0x05);
    ov2718_write_register(ViPipe, 0x7765, 0x03);
    ov2718_write_register(ViPipe, 0x7766, 0x05);
    ov2718_write_register(ViPipe, 0x7767, 0x32);
    ov2718_write_register(ViPipe, 0x7768, 0x00);
    ov2718_write_register(ViPipe, 0x7769, 0x00);
    ov2718_write_register(ViPipe, 0x776a, 0x05);
    ov2718_write_register(ViPipe, 0x776b, 0x70);
    ov2718_write_register(ViPipe, 0x776c, 0x00);
    ov2718_write_register(ViPipe, 0x776d, 0x01);
    ov2718_write_register(ViPipe, 0x776e, 0x05);
    ov2718_write_register(ViPipe, 0x776f, 0x74);
    ov2718_write_register(ViPipe, 0x7770, 0x02);
    ov2718_write_register(ViPipe, 0x7771, 0x90);
    ov2718_write_register(ViPipe, 0x7772, 0x05);
    ov2718_write_register(ViPipe, 0x7773, 0x03);
    ov2718_write_register(ViPipe, 0x7774, 0x07);
    ov2718_write_register(ViPipe, 0x7775, 0x00);
    ov2718_write_register(ViPipe, 0x7776, 0x0f);
    ov2718_write_register(ViPipe, 0x7777, 0x00);
    ov2718_write_register(ViPipe, 0x7778, 0x08);
    ov2718_write_register(ViPipe, 0x7779, 0x31);
    ov2718_write_register(ViPipe, 0x777a, 0x08);
    ov2718_write_register(ViPipe, 0x777b, 0xd2);
    ov2718_write_register(ViPipe, 0x777c, 0x0f);
    ov2718_write_register(ViPipe, 0x777d, 0x00);
    ov2718_write_register(ViPipe, 0x777e, 0x04);
    ov2718_write_register(ViPipe, 0x777f, 0xe5);
    ov2718_write_register(ViPipe, 0x7780, 0x06);
    ov2718_write_register(ViPipe, 0x7781, 0x50);
    ov2718_write_register(ViPipe, 0x7782, 0x04);
    ov2718_write_register(ViPipe, 0x7783, 0xe4);
    ov2718_write_register(ViPipe, 0x7784, 0x00);
    ov2718_write_register(ViPipe, 0x7785, 0x00);
    ov2718_write_register(ViPipe, 0x7786, 0x06);
    ov2718_write_register(ViPipe, 0x7787, 0x5c);
    ov2718_write_register(ViPipe, 0x7788, 0x09);
    ov2718_write_register(ViPipe, 0x7789, 0x15);
    ov2718_write_register(ViPipe, 0x778a, 0x06);
    ov2718_write_register(ViPipe, 0x778b, 0x1c);
    ov2718_write_register(ViPipe, 0x778c, 0x00);
    ov2718_write_register(ViPipe, 0x778d, 0x02);
    ov2718_write_register(ViPipe, 0x778e, 0x06);
    ov2718_write_register(ViPipe, 0x778f, 0xa0);
    ov2718_write_register(ViPipe, 0x7790, 0x00);
    ov2718_write_register(ViPipe, 0x7791, 0x01);
    ov2718_write_register(ViPipe, 0x7792, 0x06);
    ov2718_write_register(ViPipe, 0x7793, 0xac);
    ov2718_write_register(ViPipe, 0x7794, 0x00);
    ov2718_write_register(ViPipe, 0x7795, 0x0f);
    ov2718_write_register(ViPipe, 0x7796, 0x05);
    ov2718_write_register(ViPipe, 0x7797, 0x30);
    ov2718_write_register(ViPipe, 0x7798, 0x0f);
    ov2718_write_register(ViPipe, 0x7799, 0x00);
    ov2718_write_register(ViPipe, 0x779a, 0x00);
    ov2718_write_register(ViPipe, 0x779b, 0x00);
    ov2718_write_register(ViPipe, 0x779c, 0x00);
    ov2718_write_register(ViPipe, 0x779d, 0x02);
    ov2718_write_register(ViPipe, 0x779e, 0x04);
    ov2718_write_register(ViPipe, 0x779f, 0xe5);
    ov2718_write_register(ViPipe, 0x77a0, 0x04);
    ov2718_write_register(ViPipe, 0x77a1, 0xe4);
    ov2718_write_register(ViPipe, 0x77a2, 0x05);
    ov2718_write_register(ViPipe, 0x77a3, 0x33);
    ov2718_write_register(ViPipe, 0x77a4, 0x07);
    ov2718_write_register(ViPipe, 0x77a5, 0x10);
    ov2718_write_register(ViPipe, 0x77a6, 0x00);
    ov2718_write_register(ViPipe, 0x77a7, 0x00);
    ov2718_write_register(ViPipe, 0x77a8, 0x07);
    ov2718_write_register(ViPipe, 0x77a9, 0x00);
    ov2718_write_register(ViPipe, 0x77aa, 0x01);
    ov2718_write_register(ViPipe, 0x77ab, 0xbb);
    ov2718_write_register(ViPipe, 0x77ac, 0x07);
    ov2718_write_register(ViPipe, 0x77ad, 0x10);
    ov2718_write_register(ViPipe, 0x77ae, 0x00);
    ov2718_write_register(ViPipe, 0x77af, 0x00);
    ov2718_write_register(ViPipe, 0x77b0, 0x07);
    ov2718_write_register(ViPipe, 0x77b1, 0x00);
    ov2718_write_register(ViPipe, 0x77b2, 0x01);
    ov2718_write_register(ViPipe, 0x77b3, 0xaa);
    ov2718_write_register(ViPipe, 0x77b4, 0x07);
    ov2718_write_register(ViPipe, 0x77b5, 0x10);
    ov2718_write_register(ViPipe, 0x77b6, 0x00);
    ov2718_write_register(ViPipe, 0x77b7, 0x00);
    ov2718_write_register(ViPipe, 0x77b8, 0x07);
    ov2718_write_register(ViPipe, 0x77b9, 0x00);
    ov2718_write_register(ViPipe, 0x77ba, 0x01);
    ov2718_write_register(ViPipe, 0x77bb, 0x99);
    ov2718_write_register(ViPipe, 0x77bc, 0x07);
    ov2718_write_register(ViPipe, 0x77bd, 0x10);
    ov2718_write_register(ViPipe, 0x77be, 0x00);
    ov2718_write_register(ViPipe, 0x77bf, 0x00);
    ov2718_write_register(ViPipe, 0x77c0, 0x07);
    ov2718_write_register(ViPipe, 0x77c1, 0x00);
    ov2718_write_register(ViPipe, 0x77c2, 0x01);
    ov2718_write_register(ViPipe, 0x77c3, 0x88);
    ov2718_write_register(ViPipe, 0x77c4, 0x07);
    ov2718_write_register(ViPipe, 0x77c5, 0x10);
    ov2718_write_register(ViPipe, 0x77c6, 0x00);
    ov2718_write_register(ViPipe, 0x77c7, 0x00);
    ov2718_write_register(ViPipe, 0x77c8, 0x07);
    ov2718_write_register(ViPipe, 0x77c9, 0x00);
    ov2718_write_register(ViPipe, 0x77ca, 0x01);
    ov2718_write_register(ViPipe, 0x77cb, 0x77);
    ov2718_write_register(ViPipe, 0x77cc, 0x07);
    ov2718_write_register(ViPipe, 0x77cd, 0x10);
    ov2718_write_register(ViPipe, 0x77ce, 0x00);
    ov2718_write_register(ViPipe, 0x77cf, 0x00);
    ov2718_write_register(ViPipe, 0x77d0, 0x07);
    ov2718_write_register(ViPipe, 0x77d1, 0x00);
    ov2718_write_register(ViPipe, 0x77d2, 0x01);
    ov2718_write_register(ViPipe, 0x77d3, 0x66);
    ov2718_write_register(ViPipe, 0x77d4, 0x07);
    ov2718_write_register(ViPipe, 0x77d5, 0x10);
    ov2718_write_register(ViPipe, 0x77d6, 0x00);
    ov2718_write_register(ViPipe, 0x77d7, 0x00);
    ov2718_write_register(ViPipe, 0x77d8, 0x07);
    ov2718_write_register(ViPipe, 0x77d9, 0x00);
    ov2718_write_register(ViPipe, 0x77da, 0x01);
    ov2718_write_register(ViPipe, 0x77db, 0x55);
    ov2718_write_register(ViPipe, 0x77dc, 0x07);
    ov2718_write_register(ViPipe, 0x77dd, 0x10);
    ov2718_write_register(ViPipe, 0x77de, 0x00);
    ov2718_write_register(ViPipe, 0x77df, 0x00);
    ov2718_write_register(ViPipe, 0x77e0, 0x07);
    ov2718_write_register(ViPipe, 0x77e1, 0x00);
    ov2718_write_register(ViPipe, 0x77e2, 0x01);
    ov2718_write_register(ViPipe, 0x77e3, 0x44);
    ov2718_write_register(ViPipe, 0x77e4, 0x07);
    ov2718_write_register(ViPipe, 0x77e5, 0x10);
    ov2718_write_register(ViPipe, 0x77e6, 0x00);
    ov2718_write_register(ViPipe, 0x77e7, 0x00);
    ov2718_write_register(ViPipe, 0x77e8, 0x07);
    ov2718_write_register(ViPipe, 0x77e9, 0x00);
    ov2718_write_register(ViPipe, 0x77ea, 0x01);
    ov2718_write_register(ViPipe, 0x77eb, 0x33);
    ov2718_write_register(ViPipe, 0x77ec, 0x07);
    ov2718_write_register(ViPipe, 0x77ed, 0x10);
    ov2718_write_register(ViPipe, 0x77ee, 0x00);
    ov2718_write_register(ViPipe, 0x77ef, 0x00);
    ov2718_write_register(ViPipe, 0x77f0, 0x07);
    ov2718_write_register(ViPipe, 0x77f1, 0x00);
    ov2718_write_register(ViPipe, 0x77f2, 0x01);
    ov2718_write_register(ViPipe, 0x77f3, 0x22);
    ov2718_write_register(ViPipe, 0x77f4, 0x07);
    ov2718_write_register(ViPipe, 0x77f5, 0x10);
    ov2718_write_register(ViPipe, 0x77f6, 0x00);
    ov2718_write_register(ViPipe, 0x77f7, 0x00);
    ov2718_write_register(ViPipe, 0x77f8, 0x07);
    ov2718_write_register(ViPipe, 0x77f9, 0x00);
    ov2718_write_register(ViPipe, 0x77fa, 0x01);
    ov2718_write_register(ViPipe, 0x77fb, 0x11);
    ov2718_write_register(ViPipe, 0x77fc, 0x07);
    ov2718_write_register(ViPipe, 0x77fd, 0x10);
    ov2718_write_register(ViPipe, 0x77fe, 0x00);
    ov2718_write_register(ViPipe, 0x77ff, 0x00);
    ov2718_write_register(ViPipe, 0x7800, 0x07);
    ov2718_write_register(ViPipe, 0x7801, 0x00);
    ov2718_write_register(ViPipe, 0x7802, 0x01);
    ov2718_write_register(ViPipe, 0x7803, 0x00);
    ov2718_write_register(ViPipe, 0x7804, 0x01);
    ov2718_write_register(ViPipe, 0x7805, 0xff);
    ov2718_write_register(ViPipe, 0x7806, 0x07);
    ov2718_write_register(ViPipe, 0x7807, 0x00);
    ov2718_write_register(ViPipe, 0x7808, 0x02);
    ov2718_write_register(ViPipe, 0x7809, 0xa0);
    ov2718_write_register(ViPipe, 0x780a, 0x0f);
    ov2718_write_register(ViPipe, 0x780b, 0x00);
    ov2718_write_register(ViPipe, 0x780c, 0x08);
    ov2718_write_register(ViPipe, 0x780d, 0x36);
    ov2718_write_register(ViPipe, 0x780e, 0x06);
    ov2718_write_register(ViPipe, 0x780f, 0x50);
    ov2718_write_register(ViPipe, 0x7810, 0x04);
    ov2718_write_register(ViPipe, 0x7811, 0xe4);
    ov2718_write_register(ViPipe, 0x7812, 0x00);
    ov2718_write_register(ViPipe, 0x7813, 0x00);
    ov2718_write_register(ViPipe, 0x7814, 0x05);
    ov2718_write_register(ViPipe, 0x7815, 0x33);
    ov2718_write_register(ViPipe, 0x7816, 0x06);
    ov2718_write_register(ViPipe, 0x7817, 0x5c);
    ov2718_write_register(ViPipe, 0x7818, 0x09);
    ov2718_write_register(ViPipe, 0x7819, 0x15);
    ov2718_write_register(ViPipe, 0x781a, 0x06);
    ov2718_write_register(ViPipe, 0x781b, 0x1c);
    ov2718_write_register(ViPipe, 0x781c, 0x05);
    ov2718_write_register(ViPipe, 0x781d, 0x33);
    ov2718_write_register(ViPipe, 0x781e, 0x00);
    ov2718_write_register(ViPipe, 0x781f, 0x01);
    ov2718_write_register(ViPipe, 0x7820, 0x06);
    ov2718_write_register(ViPipe, 0x7821, 0x24);
    ov2718_write_register(ViPipe, 0x7822, 0x00);
    ov2718_write_register(ViPipe, 0x7823, 0x01);
    ov2718_write_register(ViPipe, 0x7824, 0x06);
    ov2718_write_register(ViPipe, 0x7825, 0x20);
    ov2718_write_register(ViPipe, 0x7826, 0x0f);
    ov2718_write_register(ViPipe, 0x7827, 0x00);
    ov2718_write_register(ViPipe, 0x7828, 0x08);
    ov2718_write_register(ViPipe, 0x7829, 0x36);
    ov2718_write_register(ViPipe, 0x782a, 0x07);
    ov2718_write_register(ViPipe, 0x782b, 0x10);
    ov2718_write_register(ViPipe, 0x782c, 0x00);
    ov2718_write_register(ViPipe, 0x782d, 0x00);
    ov2718_write_register(ViPipe, 0x782e, 0x07);
    ov2718_write_register(ViPipe, 0x782f, 0x00);
    ov2718_write_register(ViPipe, 0x7830, 0x01);
    ov2718_write_register(ViPipe, 0x7831, 0xbb);
    ov2718_write_register(ViPipe, 0x7832, 0x07);
    ov2718_write_register(ViPipe, 0x7833, 0x10);
    ov2718_write_register(ViPipe, 0x7834, 0x00);
    ov2718_write_register(ViPipe, 0x7835, 0x00);
    ov2718_write_register(ViPipe, 0x7836, 0x07);
    ov2718_write_register(ViPipe, 0x7837, 0x00);
    ov2718_write_register(ViPipe, 0x7838, 0x01);
    ov2718_write_register(ViPipe, 0x7839, 0xaa);
    ov2718_write_register(ViPipe, 0x783a, 0x07);
    ov2718_write_register(ViPipe, 0x783b, 0x10);
    ov2718_write_register(ViPipe, 0x783c, 0x00);
    ov2718_write_register(ViPipe, 0x783d, 0x00);
    ov2718_write_register(ViPipe, 0x783e, 0x07);
    ov2718_write_register(ViPipe, 0x783f, 0x00);
    ov2718_write_register(ViPipe, 0x7840, 0x01);
    ov2718_write_register(ViPipe, 0x7841, 0x99);
    ov2718_write_register(ViPipe, 0x7842, 0x07);
    ov2718_write_register(ViPipe, 0x7843, 0x10);
    ov2718_write_register(ViPipe, 0x7844, 0x00);
    ov2718_write_register(ViPipe, 0x7845, 0x00);
    ov2718_write_register(ViPipe, 0x7846, 0x07);
    ov2718_write_register(ViPipe, 0x7847, 0x00);
    ov2718_write_register(ViPipe, 0x7848, 0x01);
    ov2718_write_register(ViPipe, 0x7849, 0x88);
    ov2718_write_register(ViPipe, 0x784a, 0x07);
    ov2718_write_register(ViPipe, 0x784b, 0x10);
    ov2718_write_register(ViPipe, 0x784c, 0x00);
    ov2718_write_register(ViPipe, 0x784d, 0x00);
    ov2718_write_register(ViPipe, 0x784e, 0x07);
    ov2718_write_register(ViPipe, 0x784f, 0x00);
    ov2718_write_register(ViPipe, 0x7850, 0x01);
    ov2718_write_register(ViPipe, 0x7851, 0x77);
    ov2718_write_register(ViPipe, 0x7852, 0x07);
    ov2718_write_register(ViPipe, 0x7853, 0x10);
    ov2718_write_register(ViPipe, 0x7854, 0x00);
    ov2718_write_register(ViPipe, 0x7855, 0x00);
    ov2718_write_register(ViPipe, 0x7856, 0x07);
    ov2718_write_register(ViPipe, 0x7857, 0x00);
    ov2718_write_register(ViPipe, 0x7858, 0x01);
    ov2718_write_register(ViPipe, 0x7859, 0x66);
    ov2718_write_register(ViPipe, 0x785a, 0x07);
    ov2718_write_register(ViPipe, 0x785b, 0x10);
    ov2718_write_register(ViPipe, 0x785c, 0x00);
    ov2718_write_register(ViPipe, 0x785d, 0x00);
    ov2718_write_register(ViPipe, 0x785e, 0x07);
    ov2718_write_register(ViPipe, 0x785f, 0x00);
    ov2718_write_register(ViPipe, 0x7860, 0x01);
    ov2718_write_register(ViPipe, 0x7861, 0x55);
    ov2718_write_register(ViPipe, 0x7862, 0x07);
    ov2718_write_register(ViPipe, 0x7863, 0x10);
    ov2718_write_register(ViPipe, 0x7864, 0x00);
    ov2718_write_register(ViPipe, 0x7865, 0x00);
    ov2718_write_register(ViPipe, 0x7866, 0x07);
    ov2718_write_register(ViPipe, 0x7867, 0x00);
    ov2718_write_register(ViPipe, 0x7868, 0x01);
    ov2718_write_register(ViPipe, 0x7869, 0x44);
    ov2718_write_register(ViPipe, 0x786a, 0x07);
    ov2718_write_register(ViPipe, 0x786b, 0x10);
    ov2718_write_register(ViPipe, 0x786c, 0x00);
    ov2718_write_register(ViPipe, 0x786d, 0x00);
    ov2718_write_register(ViPipe, 0x786e, 0x07);
    ov2718_write_register(ViPipe, 0x786f, 0x00);
    ov2718_write_register(ViPipe, 0x7870, 0x01);
    ov2718_write_register(ViPipe, 0x7871, 0x33);
    ov2718_write_register(ViPipe, 0x7872, 0x07);
    ov2718_write_register(ViPipe, 0x7873, 0x10);
    ov2718_write_register(ViPipe, 0x7874, 0x00);
    ov2718_write_register(ViPipe, 0x7875, 0x00);
    ov2718_write_register(ViPipe, 0x7876, 0x07);
    ov2718_write_register(ViPipe, 0x7877, 0x00);
    ov2718_write_register(ViPipe, 0x7878, 0x01);
    ov2718_write_register(ViPipe, 0x7879, 0x22);
    ov2718_write_register(ViPipe, 0x787a, 0x07);
    ov2718_write_register(ViPipe, 0x787b, 0x10);
    ov2718_write_register(ViPipe, 0x787c, 0x00);
    ov2718_write_register(ViPipe, 0x787d, 0x00);
    ov2718_write_register(ViPipe, 0x787e, 0x07);
    ov2718_write_register(ViPipe, 0x787f, 0x00);
    ov2718_write_register(ViPipe, 0x7880, 0x01);
    ov2718_write_register(ViPipe, 0x7881, 0x11);
    ov2718_write_register(ViPipe, 0x7882, 0x07);
    ov2718_write_register(ViPipe, 0x7883, 0x10);
    ov2718_write_register(ViPipe, 0x7884, 0x00);
    ov2718_write_register(ViPipe, 0x7885, 0x00);
    ov2718_write_register(ViPipe, 0x7886, 0x07);
    ov2718_write_register(ViPipe, 0x7887, 0x00);
    ov2718_write_register(ViPipe, 0x7888, 0x01);
    ov2718_write_register(ViPipe, 0x7889, 0x00);
    ov2718_write_register(ViPipe, 0x788a, 0x01);
    ov2718_write_register(ViPipe, 0x788b, 0xff);
    ov2718_write_register(ViPipe, 0x788c, 0x02);
    ov2718_write_register(ViPipe, 0x788d, 0xa0);
    ov2718_write_register(ViPipe, 0x788e, 0x0f);
    ov2718_write_register(ViPipe, 0x788f, 0x00);
    ov2718_write_register(ViPipe, 0x7890, 0x08);
    ov2718_write_register(ViPipe, 0x7891, 0x3b);
    ov2718_write_register(ViPipe, 0x7892, 0x08);
    ov2718_write_register(ViPipe, 0x7893, 0x5e);
    ov2718_write_register(ViPipe, 0x7894, 0x0f);
    ov2718_write_register(ViPipe, 0x7895, 0x00);
    ov2718_write_register(ViPipe, 0x7896, 0x04);
    ov2718_write_register(ViPipe, 0x7897, 0xc0);
    ov2718_write_register(ViPipe, 0x7898, 0x09);
    ov2718_write_register(ViPipe, 0x7899, 0x15);
    ov2718_write_register(ViPipe, 0x789a, 0x04);
    ov2718_write_register(ViPipe, 0x789b, 0x99);
    ov2718_write_register(ViPipe, 0x789c, 0x07);
    ov2718_write_register(ViPipe, 0x789d, 0x14);
    ov2718_write_register(ViPipe, 0x789e, 0x04);
    ov2718_write_register(ViPipe, 0x789f, 0x80);
    ov2718_write_register(ViPipe, 0x78a0, 0x04);
    ov2718_write_register(ViPipe, 0x78a1, 0xa4);
    ov2718_write_register(ViPipe, 0x78a2, 0x00);
    ov2718_write_register(ViPipe, 0x78a3, 0x0a);
    ov2718_write_register(ViPipe, 0x78a4, 0x04);
    ov2718_write_register(ViPipe, 0x78a5, 0xa6);
    ov2718_write_register(ViPipe, 0x78a6, 0x00);
    ov2718_write_register(ViPipe, 0x78a7, 0x00);
    ov2718_write_register(ViPipe, 0x78a8, 0x04);
    ov2718_write_register(ViPipe, 0x78a9, 0xa0);
    ov2718_write_register(ViPipe, 0x78aa, 0x04);
    ov2718_write_register(ViPipe, 0x78ab, 0x80);
    ov2718_write_register(ViPipe, 0x78ac, 0x04);
    ov2718_write_register(ViPipe, 0x78ad, 0x00);
    ov2718_write_register(ViPipe, 0x78ae, 0x05);
    ov2718_write_register(ViPipe, 0x78af, 0x03);
    ov2718_write_register(ViPipe, 0x78b0, 0x06);
    ov2718_write_register(ViPipe, 0x78b1, 0x00);
    ov2718_write_register(ViPipe, 0x78b2, 0x0f);
    ov2718_write_register(ViPipe, 0x78b3, 0x00);
    ov2718_write_register(ViPipe, 0x78b4, 0x0f);
    ov2718_write_register(ViPipe, 0x78b5, 0x00);
    ov2718_write_register(ViPipe, 0x78b6, 0x0f);
    ov2718_write_register(ViPipe, 0x78b7, 0x00);
    ov2718_write_register(ViPipe, 0x3288, 0x2a);
    ov2718_write_register(ViPipe, 0x3289, 0x00);
    ov2718_write_register(ViPipe, 0x328a, 0x15);
    ov2718_write_register(ViPipe, 0x328b, 0x00);
    ov2718_write_register(ViPipe, 0x328c, 0x0a);
    ov2718_write_register(ViPipe, 0x328d, 0x80);
    ov2718_write_register(ViPipe, 0x328e, 0x05);
    ov2718_write_register(ViPipe, 0x328f, 0x40);
    ov2718_write_register(ViPipe, 0x3290, 0x54);
    ov2718_write_register(ViPipe, 0x3291, 0x00);
    ov2718_write_register(ViPipe, 0x3292, 0x2a);
    ov2718_write_register(ViPipe, 0x3293, 0x00);
    ov2718_write_register(ViPipe, 0x3294, 0x15);
    ov2718_write_register(ViPipe, 0x3295, 0x00);
    ov2718_write_register(ViPipe, 0x3296, 0x0a);
    ov2718_write_register(ViPipe, 0x3297, 0x80);
    ov2718_write_register(ViPipe, 0x3298, 0x7f);
    ov2718_write_register(ViPipe, 0x3299, 0xff);
    ov2718_write_register(ViPipe, 0x329a, 0x54);
    ov2718_write_register(ViPipe, 0x329b, 0x00);
    ov2718_write_register(ViPipe, 0x329c, 0x2a);
    ov2718_write_register(ViPipe, 0x329d, 0x00);
    ov2718_write_register(ViPipe, 0x329e, 0x15);
    ov2718_write_register(ViPipe, 0x329f, 0x00);
    ov2718_write_register(ViPipe, 0x32a0, 0x7f);
    ov2718_write_register(ViPipe, 0x32a1, 0xff);
    ov2718_write_register(ViPipe, 0x32a2, 0x7f);
    ov2718_write_register(ViPipe, 0x32a3, 0xff);
    ov2718_write_register(ViPipe, 0x32a4, 0x54);
    ov2718_write_register(ViPipe, 0x32a5, 0x00);
    ov2718_write_register(ViPipe, 0x32a6, 0x2a);
    ov2718_write_register(ViPipe, 0x32a7, 0x00);
    ov2718_write_register(ViPipe, 0x32c8, 0x87);
    ov2718_write_register(ViPipe, 0x30b0, 0x08);
    ov2718_write_register(ViPipe, 0x30b1, 0x98);
    ov2718_write_register(ViPipe, 0x30b2, 0x04);
    ov2718_write_register(ViPipe, 0x30b3, 0x70);
    ov2718_write_register(ViPipe, 0x3196, 0x00);
    ov2718_write_register(ViPipe, 0x3197, 0x10);
    ov2718_write_register(ViPipe, 0x3195, 0x28);
    ov2718_write_register(ViPipe, 0x304b, 0x00);
    ov2718_write_register(ViPipe, 0x304d, 0xa4);
    ov2718_write_register(ViPipe, 0x3033, 0x30);
    ov2718_write_register(ViPipe, 0x315a, 0x02);
    ov2718_write_register(ViPipe, 0x315b, 0x00);
    ov2718_write_register(ViPipe, 0x315c, 0x01);
    ov2718_write_register(ViPipe, 0x315d, 0xf0);
    ov2718_write_register(ViPipe, 0x315e, 0x01);
    ov2718_write_register(ViPipe, 0x315f, 0xf0);
    ov2718_write_register(ViPipe, 0x3012, 0x01);
    ov2718_write_register(ViPipe, 0x3030, 0x02);
    ov2718_write_register(ViPipe, 0x30bb, 0x04);
    ov2718_write_register(ViPipe, 0x315a, 0x02);
    ov2718_write_register(ViPipe, 0x315b, 0x00);
    ov2718_write_register(ViPipe, 0x315c, 0x01);
    ov2718_write_register(ViPipe, 0x315d, 0x80);
    ov2718_write_register(ViPipe, 0x315e, 0x02);
    ov2718_write_register(ViPipe, 0x315f, 0x86);
    ov2718_write_register(ViPipe, 0x30a8, 0x00);
    ov2718_write_register(ViPipe, 0x30a9, 0x04);
    ov2718_write_register(ViPipe, 0x30aa, 0x00);
    ov2718_write_register(ViPipe, 0x30ab, 0x04);
    ov2718_write_register(ViPipe, 0x30ac, 0x07);
    ov2718_write_register(ViPipe, 0x30ad, 0x80);
    ov2718_write_register(ViPipe, 0x30ae, 0x04);
    ov2718_write_register(ViPipe, 0x30af, 0x38);
    ov2718_default_reg_init(ViPipe);

    printf("===ov2718 sensor built-in 1080P@30fps(2->1) init success!=====\n");

    return;
}



void ov2718_2wdr1_1080p30_init(VI_PIPE ViPipe)
{
    delay_ms(5);
    ov2718_write_register(ViPipe,  0x3013, 0x01);
    delay_ms(10);
    ov2718_write_register(ViPipe,  0x3000, 0x05);
    ov2718_write_register(ViPipe,  0x3001, 0x64);
    ov2718_write_register(ViPipe,  0x3002, 0x07);
    ov2718_write_register(ViPipe,  0x3003, 0x01);
    ov2718_write_register(ViPipe,  0x3004, 0x06);
    ov2718_write_register(ViPipe,  0x3005, 0x49);
    ov2718_write_register(ViPipe,  0x3006, 0x00);
    ov2718_write_register(ViPipe,  0x3007, 0x07);
    ov2718_write_register(ViPipe,  0x3008, 0x01);
    ov2718_write_register(ViPipe,  0x3009, 0x00);
    ov2718_write_register(ViPipe,  0x300c, 0x6c);
    ov2718_write_register(ViPipe,  0x300d, 0xe1);
    ov2718_write_register(ViPipe,  0x300e, 0x80);
    ov2718_write_register(ViPipe,  0x300f, 0x00);
    ov2718_write_register(ViPipe,  0x3012, 0x00);
    ov2718_write_register(ViPipe,  0x3013, 0x00);
    ov2718_write_register(ViPipe,  0x3014, 0x04);  //
    ov2718_write_register(ViPipe,  0x3015, 0x00);
    ov2718_write_register(ViPipe,  0x3017, 0x00);
    ov2718_write_register(ViPipe,  0x3018, 0x00);
    ov2718_write_register(ViPipe,  0x3019, 0x00);
    ov2718_write_register(ViPipe,  0x301a, 0x00);
    ov2718_write_register(ViPipe,  0x301b, 0x01);
    ov2718_write_register(ViPipe,  0x301e, 0x10);
    ov2718_write_register(ViPipe,  0x301f, 0x5f);
    ov2718_write_register(ViPipe,  0x3030, 0x02);
    ov2718_write_register(ViPipe,  0x3031, 0x62);
    ov2718_write_register(ViPipe,  0x3032, 0xf0);
    ov2718_write_register(ViPipe,  0x3033, 0x30);
    ov2718_write_register(ViPipe,  0x3034, 0x34);
    ov2718_write_register(ViPipe,  0x3035, 0x51);
    ov2718_write_register(ViPipe,  0x3036, 0x02);
    ov2718_write_register(ViPipe,  0x3037, 0x9f);
    ov2718_write_register(ViPipe,  0x3038, 0x04);
    ov2718_write_register(ViPipe,  0x3039, 0xb7);
    ov2718_write_register(ViPipe,  0x303a, 0x04);
    ov2718_write_register(ViPipe,  0x303b, 0x07);
    ov2718_write_register(ViPipe,  0x303c, 0xf0);
    ov2718_write_register(ViPipe,  0x303d, 0x00);
    ov2718_write_register(ViPipe,  0x303e, 0x0b);
    ov2718_write_register(ViPipe,  0x303f, 0xe3);
    ov2718_write_register(ViPipe,  0x3040, 0xf3);
    ov2718_write_register(ViPipe,  0x3041, 0x29);
    ov2718_write_register(ViPipe,  0x3042, 0xf6);
    ov2718_write_register(ViPipe,  0x3043, 0x65);
    ov2718_write_register(ViPipe,  0x3044, 0x06);
    ov2718_write_register(ViPipe,  0x3045, 0x0f);
    ov2718_write_register(ViPipe,  0x3046, 0x55);
    ov2718_write_register(ViPipe,  0x3047, 0xf7);
    ov2718_write_register(ViPipe,  0x3048, 0x31);
    ov2718_write_register(ViPipe,  0x3049, 0x0f);
    ov2718_write_register(ViPipe,  0x304a, 0x10);
    ov2718_write_register(ViPipe,  0x304b, 0xc0);
    ov2718_write_register(ViPipe,  0x304c, 0x33);
    ov2718_write_register(ViPipe,  0x304d, 0xa4);
    ov2718_write_register(ViPipe,  0x304e, 0x0b);
    ov2718_write_register(ViPipe,  0x304f, 0x3d);
    ov2718_write_register(ViPipe,  0x3050, 0x10);
    ov2718_write_register(ViPipe,  0x3060, 0x00);
    ov2718_write_register(ViPipe,  0x3061, 0x64);
    ov2718_write_register(ViPipe,  0x3062, 0x00);
    ov2718_write_register(ViPipe,  0x3063, 0xe4);
    ov2718_write_register(ViPipe,  0x3064, 0x0b);
    ov2718_write_register(ViPipe,  0x3065, 0x60);
    ov2718_write_register(ViPipe,  0x3066, 0x80);
    ov2718_write_register(ViPipe,  0x3080, 0x00);
    ov2718_write_register(ViPipe,  0x3081, 0x00);
    ov2718_write_register(ViPipe,  0x3082, 0x01);
    ov2718_write_register(ViPipe,  0x3083, 0xe3);
    ov2718_write_register(ViPipe,  0x3084, 0x06);
    ov2718_write_register(ViPipe,  0x3085, 0x00);
    ov2718_write_register(ViPipe,  0x3086, 0x10);
    ov2718_write_register(ViPipe,  0x3087, 0x10);
    ov2718_write_register(ViPipe,  0x3089, 0x00);
    ov2718_write_register(ViPipe,  0x308a, 0x01);
    ov2718_write_register(ViPipe,  0x3093, 0x00);
    ov2718_write_register(ViPipe,  0x30a0, 0x00);
    ov2718_write_register(ViPipe,  0x30a1, 0x00);
    ov2718_write_register(ViPipe,  0x30a2, 0x00);
    ov2718_write_register(ViPipe,  0x30a3, 0x00);
    ov2718_write_register(ViPipe,  0x30a4, 0x07);
    ov2718_write_register(ViPipe,  0x30a5, 0x8f);
    ov2718_write_register(ViPipe,  0x30a6, 0x04);
    ov2718_write_register(ViPipe,  0x30a7, 0x47);
    ov2718_write_register(ViPipe,  0x30a8, 0x00);
    ov2718_write_register(ViPipe,  0x30a9, 0x04);
    ov2718_write_register(ViPipe,  0x30aa, 0x00);
    ov2718_write_register(ViPipe,  0x30ab, 0x04);
    ov2718_write_register(ViPipe,  0x30ac, 0x07);
    ov2718_write_register(ViPipe,  0x30ad, 0x80);
    ov2718_write_register(ViPipe,  0x30ae, 0x04);
    ov2718_write_register(ViPipe,  0x30af, 0x38);
    ov2718_write_register(ViPipe,  0x30b0, 0x08);
    ov2718_write_register(ViPipe,  0x30b1, 0xae);
    ov2718_write_register(ViPipe,  0x30b2, 0x04);
    ov2718_write_register(ViPipe,  0x30b3, 0x65);
    ov2718_write_register(ViPipe,  0x30b4, 0x00);
    ov2718_write_register(ViPipe,  0x30b5, 0x00);
    ov2718_write_register(ViPipe,  0x30b6, 0x00);
    ov2718_write_register(ViPipe,  0x30b7, 0x10);
    ov2718_write_register(ViPipe,  0x30b8, 0x00);
    ov2718_write_register(ViPipe,  0x30b9, 0x02);
    ov2718_write_register(ViPipe,  0x30ba, 0x10);
    ov2718_write_register(ViPipe,  0x30bb, 0x00);
    ov2718_write_register(ViPipe,  0x30bc, 0x00);
    ov2718_write_register(ViPipe,  0x30bd, 0x03);
    ov2718_write_register(ViPipe,  0x30be, 0x5c);
    ov2718_write_register(ViPipe,  0x30bf, 0x00);
    ov2718_write_register(ViPipe,  0x30c0, 0x08);
    ov2718_write_register(ViPipe,  0x30c1, 0x00);
    ov2718_write_register(ViPipe,  0x30c2, 0x20);
    ov2718_write_register(ViPipe,  0x30c3, 0x00);
    ov2718_write_register(ViPipe,  0x30c4, 0x4a);
    ov2718_write_register(ViPipe,  0x30c5, 0x00);
    ov2718_write_register(ViPipe,  0x30c7, 0x00);
    ov2718_write_register(ViPipe,  0x30c8, 0x00);
    ov2718_write_register(ViPipe,  0x30d1, 0x00);
    ov2718_write_register(ViPipe,  0x30d2, 0x00);
    ov2718_write_register(ViPipe,  0x30d3, 0x80);
    ov2718_write_register(ViPipe,  0x30d4, 0x00);
    ov2718_write_register(ViPipe,  0x30d9, 0x09);
    ov2718_write_register(ViPipe,  0x30da, 0x64);
    ov2718_write_register(ViPipe,  0x30dd, 0x00);
    ov2718_write_register(ViPipe,  0x30de, 0x16);
    ov2718_write_register(ViPipe,  0x30df, 0x00);
    ov2718_write_register(ViPipe,  0x30e0, 0x17);
    ov2718_write_register(ViPipe,  0x30e1, 0x00);
    ov2718_write_register(ViPipe,  0x30e2, 0x18);
    ov2718_write_register(ViPipe,  0x30e3, 0x10);
    ov2718_write_register(ViPipe,  0x30e4, 0x04);
    ov2718_write_register(ViPipe,  0x30e5, 0x00);
    ov2718_write_register(ViPipe,  0x30e6, 0x00);
    ov2718_write_register(ViPipe,  0x30e7, 0x00);
    ov2718_write_register(ViPipe,  0x30e8, 0x00);
    ov2718_write_register(ViPipe,  0x30e9, 0x00);
    ov2718_write_register(ViPipe,  0x30ea, 0x00);
    ov2718_write_register(ViPipe,  0x30eb, 0x00);
    ov2718_write_register(ViPipe,  0x30ec, 0x00);
    ov2718_write_register(ViPipe,  0x30ed, 0x00);
    ov2718_write_register(ViPipe,  0x3101, 0x00);
    ov2718_write_register(ViPipe,  0x3102, 0x00);
    ov2718_write_register(ViPipe,  0x3103, 0x00);
    ov2718_write_register(ViPipe,  0x3104, 0x00);
    ov2718_write_register(ViPipe,  0x3105, 0x79);
    ov2718_write_register(ViPipe,  0x3106, 0x81);
    ov2718_write_register(ViPipe,  0x3107, 0x75);
    ov2718_write_register(ViPipe,  0x3108, 0x80);
    ov2718_write_register(ViPipe,  0x3109, 0x6c);
    ov2718_write_register(ViPipe,  0x310a, 0x83);
    ov2718_write_register(ViPipe,  0x310b, 0x69);
    ov2718_write_register(ViPipe,  0x310c, 0x43);
    ov2718_write_register(ViPipe,  0x310d, 0x42);
    ov2718_write_register(ViPipe,  0x310e, 0x00);
    ov2718_write_register(ViPipe,  0x3120, 0x00);
    ov2718_write_register(ViPipe,  0x3121, 0x00);
    ov2718_write_register(ViPipe,  0x3122, 0x00);
    ov2718_write_register(ViPipe,  0x3123, 0xf0);
    ov2718_write_register(ViPipe,  0x3124, 0x00);
    ov2718_write_register(ViPipe,  0x3125, 0xa0);
    ov2718_write_register(ViPipe,  0x3126, 0x3f);
    ov2718_write_register(ViPipe,  0x3127, 0x0f);
    ov2718_write_register(ViPipe,  0x3128, 0x00);
    ov2718_write_register(ViPipe,  0x3129, 0x3a);
    ov2718_write_register(ViPipe,  0x312a, 0x02);
    ov2718_write_register(ViPipe,  0x312b, 0x0f);
    ov2718_write_register(ViPipe,  0x312c, 0x00);
    ov2718_write_register(ViPipe,  0x312d, 0x0f);
    ov2718_write_register(ViPipe,  0x312e, 0x1d);
    ov2718_write_register(ViPipe,  0x312f, 0x00);
    ov2718_write_register(ViPipe,  0x3130, 0x00);
    ov2718_write_register(ViPipe,  0x3131, 0x00);
    ov2718_write_register(ViPipe,  0x3132, 0x00);
    ov2718_write_register(ViPipe,  0x3140, 0x02);
    ov2718_write_register(ViPipe,  0x3141, 0x03);
    ov2718_write_register(ViPipe,  0x3142, 0x00);
    ov2718_write_register(ViPipe,  0x3143, 0x00);
    ov2718_write_register(ViPipe,  0x3144, 0x00);
    ov2718_write_register(ViPipe,  0x3145, 0x00);
    ov2718_write_register(ViPipe,  0x3146, 0x00);
    ov2718_write_register(ViPipe,  0x3147, 0x00);
    ov2718_write_register(ViPipe,  0x3148, 0x00);
    ov2718_write_register(ViPipe,  0x3149, 0x00);
    ov2718_write_register(ViPipe,  0x314a, 0x00);
    ov2718_write_register(ViPipe,  0x314b, 0x00);
    ov2718_write_register(ViPipe,  0x314c, 0x00);
    ov2718_write_register(ViPipe,  0x314d, 0x00);
    ov2718_write_register(ViPipe,  0x314e, 0x1c);
    ov2718_write_register(ViPipe,  0x314f, 0x02);
    ov2718_write_register(ViPipe,  0x3150, 0x02);
    ov2718_write_register(ViPipe,  0x3151, 0x02);
    ov2718_write_register(ViPipe,  0x3152, 0x10);
    ov2718_write_register(ViPipe,  0x3153, 0x10);
    ov2718_write_register(ViPipe,  0x3154, 0x10);
    ov2718_write_register(ViPipe,  0x3155, 0x00);
    ov2718_write_register(ViPipe,  0x3156, 0x03);
    ov2718_write_register(ViPipe,  0x3157, 0x00);
    ov2718_write_register(ViPipe,  0x3158, 0x0f);
    ov2718_write_register(ViPipe,  0x3159, 0xff);
    ov2718_write_register(ViPipe,  0x315a, 0x01);
    ov2718_write_register(ViPipe,  0x315b, 0x00);
    ov2718_write_register(ViPipe,  0x315c, 0x01);
    ov2718_write_register(ViPipe,  0x315d, 0x00);
    ov2718_write_register(ViPipe,  0x315e, 0x01);
    ov2718_write_register(ViPipe,  0x315f, 0x00);
    ov2718_write_register(ViPipe,  0x3160, 0x00);
    ov2718_write_register(ViPipe,  0x3161, 0x40);
    ov2718_write_register(ViPipe,  0x3162, 0x00);
    ov2718_write_register(ViPipe,  0x3163, 0x40);
    ov2718_write_register(ViPipe,  0x3164, 0x00);
    ov2718_write_register(ViPipe,  0x3165, 0x40);
    ov2718_write_register(ViPipe,  0x3190, 0x01);
    ov2718_write_register(ViPipe,  0x3191, 0x99);
    ov2718_write_register(ViPipe,  0x3193, 0x08);
    ov2718_write_register(ViPipe,  0x3194, 0x13);
    ov2718_write_register(ViPipe,  0x3195, 0x33);
    ov2718_write_register(ViPipe,  0x3196, 0x00);
    ov2718_write_register(ViPipe,  0x3197, 0x10);
    ov2718_write_register(ViPipe,  0x3198, 0x00);
    ov2718_write_register(ViPipe,  0x3199, 0x3f);
    ov2718_write_register(ViPipe,  0x319a, 0x40);
    ov2718_write_register(ViPipe,  0x319b, 0x7f);
    ov2718_write_register(ViPipe,  0x319c, 0x80);
    ov2718_write_register(ViPipe,  0x319d, 0xbf);
    ov2718_write_register(ViPipe,  0x319e, 0xc0);
    ov2718_write_register(ViPipe,  0x319f, 0xff);
    ov2718_write_register(ViPipe,  0x31a0, 0x24);
    ov2718_write_register(ViPipe,  0x31a1, 0x55);
    ov2718_write_register(ViPipe,  0x31a2, 0x00);
    ov2718_write_register(ViPipe,  0x31a3, 0x00);
    ov2718_write_register(ViPipe,  0x31a6, 0x00);
    ov2718_write_register(ViPipe,  0x31a7, 0x00);
    ov2718_write_register(ViPipe,  0x31b0, 0x00);
    ov2718_write_register(ViPipe,  0x31b1, 0x00);
    ov2718_write_register(ViPipe,  0x31b2, 0x02);
    ov2718_write_register(ViPipe,  0x31b3, 0x00);
    ov2718_write_register(ViPipe,  0x31b4, 0x00);
    ov2718_write_register(ViPipe,  0x31b5, 0x01);
    ov2718_write_register(ViPipe,  0x31b6, 0x00);
    ov2718_write_register(ViPipe,  0x31b7, 0x00);
    ov2718_write_register(ViPipe,  0x31b8, 0x00);
    ov2718_write_register(ViPipe,  0x31b9, 0x00);
    ov2718_write_register(ViPipe,  0x31ba, 0x00);
    ov2718_write_register(ViPipe,  0x31d0, 0x3c);
    ov2718_write_register(ViPipe,  0x31d1, 0x34);
    ov2718_write_register(ViPipe,  0x31d2, 0x3c);
    ov2718_write_register(ViPipe,  0x31d3, 0x00);
    ov2718_write_register(ViPipe,  0x31d4, 0x2d);
    ov2718_write_register(ViPipe,  0x31d5, 0x00);
    ov2718_write_register(ViPipe,  0x31d6, 0x01);
    ov2718_write_register(ViPipe,  0x31d7, 0x06);
    ov2718_write_register(ViPipe,  0x31d8, 0x00);
    ov2718_write_register(ViPipe,  0x31d9, 0x64);
    ov2718_write_register(ViPipe,  0x31da, 0x00);
    ov2718_write_register(ViPipe,  0x31db, 0x28);
    ov2718_write_register(ViPipe,  0x31dc, 0x04);
    ov2718_write_register(ViPipe,  0x31dd, 0x69);
    ov2718_write_register(ViPipe,  0x31de, 0x0a);
    ov2718_write_register(ViPipe,  0x31df, 0x3c);
    ov2718_write_register(ViPipe,  0x31e0, 0x04);
    ov2718_write_register(ViPipe,  0x31e1, 0x32);
    ov2718_write_register(ViPipe,  0x31e2, 0x00);
    ov2718_write_register(ViPipe,  0x31e3, 0x01);
    ov2718_write_register(ViPipe,  0x31e4, 0x0d);
    ov2718_write_register(ViPipe,  0x31e5, 0x80);
    ov2718_write_register(ViPipe,  0x31e6, 0x00);
    ov2718_write_register(ViPipe,  0x31e7, 0x2c);
    ov2718_write_register(ViPipe,  0x31e8, 0x6c);
    ov2718_write_register(ViPipe,  0x31e9, 0xac);
    ov2718_write_register(ViPipe,  0x31ea, 0xec);
    ov2718_write_register(ViPipe,  0x31eb, 0x3f);
    ov2718_write_register(ViPipe,  0x31ec, 0x0f);
    ov2718_write_register(ViPipe,  0x31ed, 0x20);
    ov2718_write_register(ViPipe,  0x31ee, 0x04);
    ov2718_write_register(ViPipe,  0x31ef, 0x48);
    ov2718_write_register(ViPipe,  0x31f0, 0x07);
    ov2718_write_register(ViPipe,  0x31f1, 0x90);
    ov2718_write_register(ViPipe,  0x31f2, 0x04);
    ov2718_write_register(ViPipe,  0x31f3, 0x48);
    ov2718_write_register(ViPipe,  0x31f4, 0x07);
    ov2718_write_register(ViPipe,  0x31f5, 0x90);
    ov2718_write_register(ViPipe,  0x31f6, 0x04);
    ov2718_write_register(ViPipe,  0x31f7, 0x48);
    ov2718_write_register(ViPipe,  0x31f8, 0x07);
    ov2718_write_register(ViPipe,  0x31f9, 0x90);
    ov2718_write_register(ViPipe,  0x31fa, 0x04);
    ov2718_write_register(ViPipe,  0x31fb, 0x48);
    ov2718_write_register(ViPipe,  0x31fd, 0xcb);
    ov2718_write_register(ViPipe,  0x31fe, 0x0f);
    ov2718_write_register(ViPipe,  0x31ff, 0x03);
    ov2718_write_register(ViPipe,  0x3200, 0x00);
    ov2718_write_register(ViPipe,  0x3201, 0xff);
    ov2718_write_register(ViPipe,  0x3202, 0x00);
    ov2718_write_register(ViPipe,  0x3203, 0xff);
    ov2718_write_register(ViPipe,  0x3204, 0xff);
    ov2718_write_register(ViPipe,  0x3205, 0xff);
    ov2718_write_register(ViPipe,  0x3206, 0xff);
    ov2718_write_register(ViPipe,  0x3207, 0xff);
    ov2718_write_register(ViPipe,  0x3208, 0xff);
    ov2718_write_register(ViPipe,  0x3209, 0xff);
    ov2718_write_register(ViPipe,  0x320a, 0xff);
    ov2718_write_register(ViPipe,  0x320b, 0x1b);
    ov2718_write_register(ViPipe,  0x320c, 0x1f);
    ov2718_write_register(ViPipe,  0x320d, 0x1e);
    ov2718_write_register(ViPipe,  0x320e, 0x30);
    ov2718_write_register(ViPipe,  0x320f, 0x2d);
    ov2718_write_register(ViPipe,  0x3210, 0x2c);
    ov2718_write_register(ViPipe,  0x3211, 0x2b);
    ov2718_write_register(ViPipe,  0x3212, 0x2a);
    ov2718_write_register(ViPipe,  0x3213, 0x24);
    ov2718_write_register(ViPipe,  0x3214, 0x22);
    ov2718_write_register(ViPipe,  0x3215, 0x00);
    ov2718_write_register(ViPipe,  0x3216, 0x04);
    ov2718_write_register(ViPipe,  0x3217, 0x2c);
    ov2718_write_register(ViPipe,  0x3218, 0x6c);
    ov2718_write_register(ViPipe,  0x3219, 0xac);
    ov2718_write_register(ViPipe,  0x321a, 0xec);
    ov2718_write_register(ViPipe,  0x321b, 0x00);
    ov2718_write_register(ViPipe,  0x3230, 0x3a);
    ov2718_write_register(ViPipe,  0x3231, 0x00);
    ov2718_write_register(ViPipe,  0x3232, 0x80);
    ov2718_write_register(ViPipe,  0x3233, 0x00);
    ov2718_write_register(ViPipe,  0x3234, 0x10);
    ov2718_write_register(ViPipe,  0x3235, 0xaa);
    ov2718_write_register(ViPipe,  0x3236, 0x55);
    ov2718_write_register(ViPipe,  0x3237, 0x99);
    ov2718_write_register(ViPipe,  0x3238, 0x66);
    ov2718_write_register(ViPipe,  0x3239, 0x08);
    ov2718_write_register(ViPipe,  0x323a, 0x88);
    ov2718_write_register(ViPipe,  0x323b, 0x00);
    ov2718_write_register(ViPipe,  0x323c, 0x00);
    ov2718_write_register(ViPipe,  0x323d, 0x03);
    ov2718_write_register(ViPipe,  0x3250, 0x33);
    ov2718_write_register(ViPipe,  0x3251, 0x00);
    ov2718_write_register(ViPipe,  0x3252, 0x20);
    ov2718_write_register(ViPipe,  0x3253, 0x00);
    ov2718_write_register(ViPipe,  0x3254, 0x11);
    ov2718_write_register(ViPipe,  0x3255, 0x01);
    ov2718_write_register(ViPipe,  0x3256, 0x00);
    ov2718_write_register(ViPipe,  0x3257, 0x00);
    ov2718_write_register(ViPipe,  0x3258, 0x00);
    ov2718_write_register(ViPipe,  0x3270, 0x01);
    ov2718_write_register(ViPipe,  0x3271, 0x60);
    ov2718_write_register(ViPipe,  0x3272, 0xc0);
    ov2718_write_register(ViPipe,  0x3273, 0x00);
    ov2718_write_register(ViPipe,  0x3274, 0x80);
    ov2718_write_register(ViPipe,  0x3275, 0x40);
    ov2718_write_register(ViPipe,  0x3276, 0x02);
    ov2718_write_register(ViPipe,  0x3277, 0x08);
    ov2718_write_register(ViPipe,  0x3278, 0x10);
    ov2718_write_register(ViPipe,  0x3279, 0x04);
    ov2718_write_register(ViPipe,  0x327a, 0x00);
    ov2718_write_register(ViPipe,  0x327b, 0x03);
    ov2718_write_register(ViPipe,  0x327c, 0x10);
    ov2718_write_register(ViPipe,  0x327d, 0x60);
    ov2718_write_register(ViPipe,  0x327e, 0xc0);
    ov2718_write_register(ViPipe,  0x327f, 0x06);
    ov2718_write_register(ViPipe,  0x3288, 0x10);
    ov2718_write_register(ViPipe,  0x3289, 0x00);
    ov2718_write_register(ViPipe,  0x328a, 0x08);
    ov2718_write_register(ViPipe,  0x328b, 0x00);
    ov2718_write_register(ViPipe,  0x328c, 0x04);
    ov2718_write_register(ViPipe,  0x328d, 0x00);
    ov2718_write_register(ViPipe,  0x328e, 0x02);
    ov2718_write_register(ViPipe,  0x328f, 0x00);
    ov2718_write_register(ViPipe,  0x3290, 0x20);
    ov2718_write_register(ViPipe,  0x3291, 0x00);
    ov2718_write_register(ViPipe,  0x3292, 0x10);
    ov2718_write_register(ViPipe,  0x3293, 0x00);
    ov2718_write_register(ViPipe,  0x3294, 0x08);
    ov2718_write_register(ViPipe,  0x3295, 0x00);
    ov2718_write_register(ViPipe,  0x3296, 0x04);
    ov2718_write_register(ViPipe,  0x3297, 0x00);
    ov2718_write_register(ViPipe,  0x3298, 0x40);
    ov2718_write_register(ViPipe,  0x3299, 0x00);
    ov2718_write_register(ViPipe,  0x329a, 0x20);
    ov2718_write_register(ViPipe,  0x329b, 0x00);
    ov2718_write_register(ViPipe,  0x329c, 0x10);
    ov2718_write_register(ViPipe,  0x329d, 0x00);
    ov2718_write_register(ViPipe,  0x329e, 0x08);
    ov2718_write_register(ViPipe,  0x329f, 0x00);
    ov2718_write_register(ViPipe,  0x32a0, 0x7f);
    ov2718_write_register(ViPipe,  0x32a1, 0xff);
    ov2718_write_register(ViPipe,  0x32a2, 0x40);
    ov2718_write_register(ViPipe,  0x32a3, 0x00);
    ov2718_write_register(ViPipe,  0x32a4, 0x20);
    ov2718_write_register(ViPipe,  0x32a5, 0x00);
    ov2718_write_register(ViPipe,  0x32a6, 0x10);
    ov2718_write_register(ViPipe,  0x32a7, 0x00);
    ov2718_write_register(ViPipe,  0x32a8, 0x00);
    ov2718_write_register(ViPipe,  0x32a9, 0x00);
    ov2718_write_register(ViPipe,  0x32aa, 0x00);
    ov2718_write_register(ViPipe,  0x32ab, 0x00);
    ov2718_write_register(ViPipe,  0x32ac, 0x00);
    ov2718_write_register(ViPipe,  0x32ad, 0x00);
    ov2718_write_register(ViPipe,  0x32ae, 0x00);
    ov2718_write_register(ViPipe,  0x32af, 0x00);
    ov2718_write_register(ViPipe,  0x32b0, 0x00);
    ov2718_write_register(ViPipe,  0x32b1, 0x00);
    ov2718_write_register(ViPipe,  0x32b2, 0x00);
    ov2718_write_register(ViPipe,  0x32b3, 0x00);
    ov2718_write_register(ViPipe,  0x32b4, 0x00);
    ov2718_write_register(ViPipe,  0x32b5, 0x00);
    ov2718_write_register(ViPipe,  0x32b6, 0x00);
    ov2718_write_register(ViPipe,  0x32b7, 0x00);
    ov2718_write_register(ViPipe,  0x32b8, 0x00);
    ov2718_write_register(ViPipe,  0x32b9, 0x00);
    ov2718_write_register(ViPipe,  0x32ba, 0x00);
    ov2718_write_register(ViPipe,  0x32bb, 0x00);
    ov2718_write_register(ViPipe,  0x32bc, 0x00);
    ov2718_write_register(ViPipe,  0x32bd, 0x00);
    ov2718_write_register(ViPipe,  0x32be, 0x00);
    ov2718_write_register(ViPipe,  0x32bf, 0x00);
    ov2718_write_register(ViPipe,  0x32c0, 0x00);
    ov2718_write_register(ViPipe,  0x32c1, 0x00);
    ov2718_write_register(ViPipe,  0x32c2, 0x00);
    ov2718_write_register(ViPipe,  0x32c3, 0x00);
    ov2718_write_register(ViPipe,  0x32c4, 0x00);
    ov2718_write_register(ViPipe,  0x32c5, 0x00);
    ov2718_write_register(ViPipe,  0x32c6, 0x00);
    ov2718_write_register(ViPipe,  0x32c7, 0x00);
    ov2718_write_register(ViPipe,  0x32c8, 0x87);
    ov2718_write_register(ViPipe,  0x32c9, 0x00);
    ov2718_write_register(ViPipe,  0x3330, 0x03);
    ov2718_write_register(ViPipe,  0x3331, 0xc8);
    ov2718_write_register(ViPipe,  0x3332, 0x02);
    ov2718_write_register(ViPipe,  0x3333, 0x24);
    ov2718_write_register(ViPipe,  0x3334, 0x00);
    ov2718_write_register(ViPipe,  0x3335, 0x00);
    ov2718_write_register(ViPipe,  0x3336, 0x00);
    ov2718_write_register(ViPipe,  0x3337, 0x00);
    ov2718_write_register(ViPipe,  0x3338, 0x03);
    ov2718_write_register(ViPipe,  0x3339, 0xc8);
    ov2718_write_register(ViPipe,  0x333a, 0x02);
    ov2718_write_register(ViPipe,  0x333b, 0x24);
    ov2718_write_register(ViPipe,  0x333c, 0x00);
    ov2718_write_register(ViPipe,  0x333d, 0x00);
    ov2718_write_register(ViPipe,  0x333e, 0x00);
    ov2718_write_register(ViPipe,  0x333f, 0x00);
    ov2718_write_register(ViPipe,  0x3340, 0x03);
    ov2718_write_register(ViPipe,  0x3341, 0xc8);
    ov2718_write_register(ViPipe,  0x3342, 0x02);
    ov2718_write_register(ViPipe,  0x3343, 0x24);
    ov2718_write_register(ViPipe,  0x3344, 0x00);
    ov2718_write_register(ViPipe,  0x3345, 0x00);
    ov2718_write_register(ViPipe,  0x3346, 0x00);
    ov2718_write_register(ViPipe,  0x3347, 0x00);
    ov2718_write_register(ViPipe,  0x3348, 0x40);
    ov2718_write_register(ViPipe,  0x3349, 0x00);
    ov2718_write_register(ViPipe,  0x334a, 0x00);
    ov2718_write_register(ViPipe,  0x334b, 0x00);
    ov2718_write_register(ViPipe,  0x334c, 0x00);
    ov2718_write_register(ViPipe,  0x334d, 0x00);
    ov2718_write_register(ViPipe,  0x334e, 0x80);
    ov2718_write_register(ViPipe,  0x3360, 0x01);
    ov2718_write_register(ViPipe,  0x3361, 0x00);
    ov2718_write_register(ViPipe,  0x3362, 0x01);
    ov2718_write_register(ViPipe,  0x3363, 0x00);
    ov2718_write_register(ViPipe,  0x3364, 0x01);
    ov2718_write_register(ViPipe,  0x3365, 0x00);
    ov2718_write_register(ViPipe,  0x3366, 0x01);
    ov2718_write_register(ViPipe,  0x3367, 0x00);
    ov2718_write_register(ViPipe,  0x3368, 0x01);
    ov2718_write_register(ViPipe,  0x3369, 0x00);
    ov2718_write_register(ViPipe,  0x336a, 0x01);
    ov2718_write_register(ViPipe,  0x336b, 0x00);
    ov2718_write_register(ViPipe,  0x336c, 0x01);
    ov2718_write_register(ViPipe,  0x336d, 0x00);
    ov2718_write_register(ViPipe,  0x336e, 0x01);
    ov2718_write_register(ViPipe,  0x336f, 0x00);
    ov2718_write_register(ViPipe,  0x3370, 0x01);
    ov2718_write_register(ViPipe,  0x3371, 0x00);
    ov2718_write_register(ViPipe,  0x3372, 0x01);
    ov2718_write_register(ViPipe,  0x3373, 0x00);
    ov2718_write_register(ViPipe,  0x3374, 0x01);
    ov2718_write_register(ViPipe,  0x3375, 0x00);
    ov2718_write_register(ViPipe,  0x3376, 0x01);
    ov2718_write_register(ViPipe,  0x3377, 0x00);
    ov2718_write_register(ViPipe,  0x3378, 0x00);
    ov2718_write_register(ViPipe,  0x3379, 0x00);
    ov2718_write_register(ViPipe,  0x337a, 0x00);
    ov2718_write_register(ViPipe,  0x337b, 0x00);
    ov2718_write_register(ViPipe,  0x337c, 0x00);
    ov2718_write_register(ViPipe,  0x337d, 0x00);
    ov2718_write_register(ViPipe,  0x337e, 0x00);
    ov2718_write_register(ViPipe,  0x337f, 0x00);
    ov2718_write_register(ViPipe,  0x3380, 0x00);
    ov2718_write_register(ViPipe,  0x3381, 0x00);
    ov2718_write_register(ViPipe,  0x3382, 0x00);
    ov2718_write_register(ViPipe,  0x3383, 0x00);
    ov2718_write_register(ViPipe,  0x3384, 0x00);
    ov2718_write_register(ViPipe,  0x3385, 0x00);
    ov2718_write_register(ViPipe,  0x3386, 0x00);
    ov2718_write_register(ViPipe,  0x3387, 0x00);
    ov2718_write_register(ViPipe,  0x3388, 0x00);
    ov2718_write_register(ViPipe,  0x3389, 0x00);
    ov2718_write_register(ViPipe,  0x338a, 0x00);
    ov2718_write_register(ViPipe,  0x338b, 0x00);
    ov2718_write_register(ViPipe,  0x338c, 0x00);
    ov2718_write_register(ViPipe,  0x338d, 0x00);
    ov2718_write_register(ViPipe,  0x338e, 0x00);
    ov2718_write_register(ViPipe,  0x338f, 0x00);
    ov2718_write_register(ViPipe,  0x3390, 0x00);
    ov2718_write_register(ViPipe,  0x3391, 0x00);
    ov2718_write_register(ViPipe,  0x3392, 0x00);
    ov2718_write_register(ViPipe,  0x3393, 0x00);
    ov2718_write_register(ViPipe,  0x3394, 0x00);
    ov2718_write_register(ViPipe,  0x3395, 0x00);
    ov2718_write_register(ViPipe,  0x3396, 0x00);
    ov2718_write_register(ViPipe,  0x3397, 0x00);
    ov2718_write_register(ViPipe,  0x3398, 0x00);
    ov2718_write_register(ViPipe,  0x3399, 0x00);
    ov2718_write_register(ViPipe,  0x339a, 0x00);
    ov2718_write_register(ViPipe,  0x339b, 0x00);
    ov2718_write_register(ViPipe,  0x33b0, 0x00);
    ov2718_write_register(ViPipe,  0x33b1, 0x50);
    ov2718_write_register(ViPipe,  0x33b2, 0x01);
    ov2718_write_register(ViPipe,  0x33b3, 0xff);
    ov2718_write_register(ViPipe,  0x33b4, 0xe0);
    ov2718_write_register(ViPipe,  0x33b5, 0x6b);
    ov2718_write_register(ViPipe,  0x33b6, 0x00);
    ov2718_write_register(ViPipe,  0x33b7, 0x00);
    ov2718_write_register(ViPipe,  0x33b8, 0x00);
    ov2718_write_register(ViPipe,  0x33b9, 0x00);
    ov2718_write_register(ViPipe,  0x33ba, 0x02);
    ov2718_write_register(ViPipe,  0x33bb, 0x08);
    ov2718_write_register(ViPipe,  0x33bc, 0x01);
    ov2718_write_register(ViPipe,  0x33bd, 0x01);
    ov2718_write_register(ViPipe,  0x33be, 0x01);
    ov2718_write_register(ViPipe,  0x33bf, 0x01);
    ov2718_write_register(ViPipe,  0x33c0, 0x00);
    ov2718_write_register(ViPipe,  0x33c1, 0x00);
    ov2718_write_register(ViPipe,  0x33c2, 0x00);
    ov2718_write_register(ViPipe,  0x33c3, 0x00);
    ov2718_write_register(ViPipe,  0x33e0, 0x14);
    ov2718_write_register(ViPipe,  0x33e1, 0x0f);
    ov2718_write_register(ViPipe,  0x33e2, 0x04);
    ov2718_write_register(ViPipe,  0x33e3, 0x02);
    ov2718_write_register(ViPipe,  0x33e4, 0x01);
    ov2718_write_register(ViPipe,  0x33e5, 0x01);
    ov2718_write_register(ViPipe,  0x33e6, 0x00);
    ov2718_write_register(ViPipe,  0x33e7, 0x04);
    ov2718_write_register(ViPipe,  0x33e8, 0x0c);
    ov2718_write_register(ViPipe,  0x33e9, 0x00);
    ov2718_write_register(ViPipe,  0x33ea, 0x01);
    ov2718_write_register(ViPipe,  0x33eb, 0x02);
    ov2718_write_register(ViPipe,  0x33ec, 0x03);
    ov2718_write_register(ViPipe,  0x33ed, 0x02);
    ov2718_write_register(ViPipe,  0x33ee, 0x05);
    ov2718_write_register(ViPipe,  0x33ef, 0x0a);
    ov2718_write_register(ViPipe,  0x33f0, 0x08);
    ov2718_write_register(ViPipe,  0x33f1, 0x04);
    ov2718_write_register(ViPipe,  0x33f2, 0x04);
    ov2718_write_register(ViPipe,  0x33f3, 0x00);
    ov2718_write_register(ViPipe,  0x33f4, 0x03);
    ov2718_write_register(ViPipe,  0x33f5, 0x14);
    ov2718_write_register(ViPipe,  0x33f6, 0x0f);
    ov2718_write_register(ViPipe,  0x33f7, 0x02);
    ov2718_write_register(ViPipe,  0x33f8, 0x01);
    ov2718_write_register(ViPipe,  0x33f9, 0x01);
    ov2718_write_register(ViPipe,  0x33fa, 0x01);
    ov2718_write_register(ViPipe,  0x33fb, 0x00);
    ov2718_write_register(ViPipe,  0x33fc, 0x04);
    ov2718_write_register(ViPipe,  0x33fd, 0x0c);
    ov2718_write_register(ViPipe,  0x33fe, 0x00);
    ov2718_write_register(ViPipe,  0x33ff, 0x01);
    ov2718_write_register(ViPipe,  0x3400, 0x02);
    ov2718_write_register(ViPipe,  0x3401, 0x03);
    ov2718_write_register(ViPipe,  0x3402, 0x01);
    ov2718_write_register(ViPipe,  0x3403, 0x02);
    ov2718_write_register(ViPipe,  0x3404, 0x08);
    ov2718_write_register(ViPipe,  0x3405, 0x08);
    ov2718_write_register(ViPipe,  0x3406, 0x04);
    ov2718_write_register(ViPipe,  0x3407, 0x04);
    ov2718_write_register(ViPipe,  0x3408, 0x00);
    ov2718_write_register(ViPipe,  0x3409, 0x03);
    ov2718_write_register(ViPipe,  0x340a, 0x14);
    ov2718_write_register(ViPipe,  0x340b, 0x0f);
    ov2718_write_register(ViPipe,  0x340c, 0x04);
    ov2718_write_register(ViPipe,  0x340d, 0x02);
    ov2718_write_register(ViPipe,  0x340e, 0x01);
    ov2718_write_register(ViPipe,  0x340f, 0x01);
    ov2718_write_register(ViPipe,  0x3410, 0x00);
    ov2718_write_register(ViPipe,  0x3411, 0x04);
    ov2718_write_register(ViPipe,  0x3412, 0x0c);
    ov2718_write_register(ViPipe,  0x3413, 0x00);
    ov2718_write_register(ViPipe,  0x3414, 0x01);
    ov2718_write_register(ViPipe,  0x3415, 0x02);
    ov2718_write_register(ViPipe,  0x3416, 0x03);
    ov2718_write_register(ViPipe,  0x3417, 0x02);
    ov2718_write_register(ViPipe,  0x3418, 0x05);
    ov2718_write_register(ViPipe,  0x3419, 0x0a);
    ov2718_write_register(ViPipe,  0x341a, 0x08);
    ov2718_write_register(ViPipe,  0x341b, 0x04);
    ov2718_write_register(ViPipe,  0x341c, 0x04);
    ov2718_write_register(ViPipe,  0x341d, 0x00);
    ov2718_write_register(ViPipe,  0x341e, 0x03);
    ov2718_write_register(ViPipe,  0x3440, 0x00);
    ov2718_write_register(ViPipe,  0x3441, 0x00);
    ov2718_write_register(ViPipe,  0x3442, 0x00);
    ov2718_write_register(ViPipe,  0x3443, 0x00);
    ov2718_write_register(ViPipe,  0x3444, 0x02);
    ov2718_write_register(ViPipe,  0x3445, 0xf0);
    ov2718_write_register(ViPipe,  0x3446, 0x02);
    ov2718_write_register(ViPipe,  0x3447, 0x08);
    ov2718_write_register(ViPipe,  0x3448, 0x00);
    ov2718_write_register(ViPipe,  0x3460, 0x40);
    ov2718_write_register(ViPipe,  0x3461, 0x40);
    ov2718_write_register(ViPipe,  0x3462, 0x40);
    ov2718_write_register(ViPipe,  0x3463, 0x40);
    ov2718_write_register(ViPipe,  0x3464, 0x03);
    ov2718_write_register(ViPipe,  0x3465, 0x01);
    ov2718_write_register(ViPipe,  0x3466, 0x01);
    ov2718_write_register(ViPipe,  0x3467, 0x02);
    ov2718_write_register(ViPipe,  0x3468, 0x30);
    ov2718_write_register(ViPipe,  0x3469, 0x00);
    ov2718_write_register(ViPipe,  0x346a, 0x35);
    ov2718_write_register(ViPipe,  0x346b, 0x00);
    ov2718_write_register(ViPipe,  0x3480, 0x40);
    ov2718_write_register(ViPipe,  0x3481, 0x00);
    ov2718_write_register(ViPipe,  0x3482, 0x00);
    ov2718_write_register(ViPipe,  0x3483, 0x00);
    ov2718_write_register(ViPipe,  0x3484, 0x07);
    ov2718_write_register(ViPipe,  0x3485, 0x00);
    ov2718_write_register(ViPipe,  0x3486, 0x00);
    ov2718_write_register(ViPipe,  0x3487, 0x00);
    ov2718_write_register(ViPipe,  0x3488, 0x00);
    ov2718_write_register(ViPipe,  0x3489, 0x00);
    ov2718_write_register(ViPipe,  0x348a, 0x00);
    ov2718_write_register(ViPipe,  0x348b, 0x04);
    ov2718_write_register(ViPipe,  0x348c, 0x00);
    ov2718_write_register(ViPipe,  0x348d, 0x01);
    ov2718_write_register(ViPipe,  0x348f, 0x01);
    ov2718_write_register(ViPipe,  0x7000, 0x1a);
    ov2718_write_register(ViPipe,  0x7001, 0xc1);
    ov2718_write_register(ViPipe,  0x7002, 0x02);
    ov2718_write_register(ViPipe,  0x7003, 0xda);
    ov2718_write_register(ViPipe,  0x7004, 0xbd);
    ov2718_write_register(ViPipe,  0x7005, 0x03);
    ov2718_write_register(ViPipe,  0x7006, 0xbd);
    ov2718_write_register(ViPipe,  0x7007, 0x06);
    ov2718_write_register(ViPipe,  0x7008, 0xe6);
    ov2718_write_register(ViPipe,  0x7009, 0xec);
    ov2718_write_register(ViPipe,  0x700a, 0x19);
    ov2718_write_register(ViPipe,  0x700b, 0xc2);
    ov2718_write_register(ViPipe,  0x700c, 0x0a);
    ov2718_write_register(ViPipe,  0x700d, 0xbc);
    ov2718_write_register(ViPipe,  0x700e, 0xf0);
    ov2718_write_register(ViPipe,  0x700f, 0xbc);
    ov2718_write_register(ViPipe,  0x7010, 0xf0);
    ov2718_write_register(ViPipe,  0x7011, 0x00);
    ov2718_write_register(ViPipe,  0x7012, 0xc0);
    ov2718_write_register(ViPipe,  0x7013, 0x0c);
    ov2718_write_register(ViPipe,  0x7014, 0xbc);
    ov2718_write_register(ViPipe,  0x7015, 0x8c);
    ov2718_write_register(ViPipe,  0x7016, 0xbc);
    ov2718_write_register(ViPipe,  0x7017, 0x14);
    ov2718_write_register(ViPipe,  0x7018, 0xda);
    ov2718_write_register(ViPipe,  0x7019, 0x76);
    ov2718_write_register(ViPipe,  0x701a, 0xb6);
    ov2718_write_register(ViPipe,  0x701b, 0xee);
    ov2718_write_register(ViPipe,  0x701c, 0xcf);
    ov2718_write_register(ViPipe,  0x701d, 0xac);
    ov2718_write_register(ViPipe,  0x701e, 0xd0);
    ov2718_write_register(ViPipe,  0x701f, 0xac);
    ov2718_write_register(ViPipe,  0x7020, 0xd1);
    ov2718_write_register(ViPipe,  0x7021, 0x50);
    ov2718_write_register(ViPipe,  0x7022, 0xac);
    ov2718_write_register(ViPipe,  0x7023, 0xd2);
    ov2718_write_register(ViPipe,  0x7024, 0xbc);
    ov2718_write_register(ViPipe,  0x7025, 0x2e);
    ov2718_write_register(ViPipe,  0x7026, 0xb4);
    ov2718_write_register(ViPipe,  0x7027, 0x00);
    ov2718_write_register(ViPipe,  0x7028, 0xdc);
    ov2718_write_register(ViPipe,  0x7029, 0xdf);
    ov2718_write_register(ViPipe,  0x702a, 0xb0);
    ov2718_write_register(ViPipe,  0x702b, 0x6e);
    ov2718_write_register(ViPipe,  0x702c, 0xbd);
    ov2718_write_register(ViPipe,  0x702d, 0x01);
    ov2718_write_register(ViPipe,  0x702e, 0xd7);
    ov2718_write_register(ViPipe,  0x702f, 0xed);
    ov2718_write_register(ViPipe,  0x7030, 0xe1);
    ov2718_write_register(ViPipe,  0x7031, 0x36);
    ov2718_write_register(ViPipe,  0x7032, 0x30);
    ov2718_write_register(ViPipe,  0x7033, 0xd3);
    ov2718_write_register(ViPipe,  0x7034, 0x2e);
    ov2718_write_register(ViPipe,  0x7035, 0x54);
    ov2718_write_register(ViPipe,  0x7036, 0x46);
    ov2718_write_register(ViPipe,  0x7037, 0xbc);
    ov2718_write_register(ViPipe,  0x7038, 0x22);
    ov2718_write_register(ViPipe,  0x7039, 0x66);
    ov2718_write_register(ViPipe,  0x703a, 0xbc);
    ov2718_write_register(ViPipe,  0x703b, 0x24);
    ov2718_write_register(ViPipe,  0x703c, 0x2c);
    ov2718_write_register(ViPipe,  0x703d, 0x28);
    ov2718_write_register(ViPipe,  0x703e, 0xbc);
    ov2718_write_register(ViPipe,  0x703f, 0x3c);
    ov2718_write_register(ViPipe,  0x7040, 0xa1);
    ov2718_write_register(ViPipe,  0x7041, 0xac);
    ov2718_write_register(ViPipe,  0x7042, 0xd8);
    ov2718_write_register(ViPipe,  0x7043, 0xd6);
    ov2718_write_register(ViPipe,  0x7044, 0xb4);
    ov2718_write_register(ViPipe,  0x7045, 0x04);
    ov2718_write_register(ViPipe,  0x7046, 0x46);
    ov2718_write_register(ViPipe,  0x7047, 0xb7);
    ov2718_write_register(ViPipe,  0x7048, 0x00);
    ov2718_write_register(ViPipe,  0x7049, 0xbe);
    ov2718_write_register(ViPipe,  0x704a, 0x08);
    ov2718_write_register(ViPipe,  0x704b, 0xc3);
    ov2718_write_register(ViPipe,  0x704c, 0xd7);
    ov2718_write_register(ViPipe,  0x704d, 0xad);
    ov2718_write_register(ViPipe,  0x704e, 0xc3);
    ov2718_write_register(ViPipe,  0x704f, 0xbc);
    ov2718_write_register(ViPipe,  0x7050, 0x19);
    ov2718_write_register(ViPipe,  0x7051, 0xc1);
    ov2718_write_register(ViPipe,  0x7052, 0x2a);
    ov2718_write_register(ViPipe,  0x7053, 0xe7);
    ov2718_write_register(ViPipe,  0x7054, 0x50);
    ov2718_write_register(ViPipe,  0x7055, 0x20);
    ov2718_write_register(ViPipe,  0x7056, 0xb8);
    ov2718_write_register(ViPipe,  0x7057, 0x02);
    ov2718_write_register(ViPipe,  0x7058, 0xbc);
    ov2718_write_register(ViPipe,  0x7059, 0x17);
    ov2718_write_register(ViPipe,  0x705a, 0xdb);
    ov2718_write_register(ViPipe,  0x705b, 0xc7);
    ov2718_write_register(ViPipe,  0x705c, 0xb8);
    ov2718_write_register(ViPipe,  0x705d, 0x00);
    ov2718_write_register(ViPipe,  0x705e, 0x28);
    ov2718_write_register(ViPipe,  0x705f, 0x54);
    ov2718_write_register(ViPipe,  0x7060, 0xb4);
    ov2718_write_register(ViPipe,  0x7061, 0x14);
    ov2718_write_register(ViPipe,  0x7062, 0xab);
    ov2718_write_register(ViPipe,  0x7063, 0xbe);
    ov2718_write_register(ViPipe,  0x7064, 0x06);
    ov2718_write_register(ViPipe,  0x7065, 0xd8);
    ov2718_write_register(ViPipe,  0x7066, 0xd6);
    ov2718_write_register(ViPipe,  0x7067, 0x00);
    ov2718_write_register(ViPipe,  0x7068, 0xb4);
    ov2718_write_register(ViPipe,  0x7069, 0xbc);
    ov2718_write_register(ViPipe,  0x706a, 0xb9);
    ov2718_write_register(ViPipe,  0x706b, 0x64);
    ov2718_write_register(ViPipe,  0x706c, 0xbc);
    ov2718_write_register(ViPipe,  0x706d, 0x16);
    ov2718_write_register(ViPipe,  0x706e, 0x62);
    ov2718_write_register(ViPipe,  0x706f, 0x05);
    ov2718_write_register(ViPipe,  0x7070, 0xee);
    ov2718_write_register(ViPipe,  0x7071, 0xe6);
    ov2718_write_register(ViPipe,  0x7072, 0xb9);
    ov2718_write_register(ViPipe,  0x7073, 0x05);
    ov2718_write_register(ViPipe,  0x7074, 0xad);
    ov2718_write_register(ViPipe,  0x7075, 0xb4);
    ov2718_write_register(ViPipe,  0x7076, 0x25);
    ov2718_write_register(ViPipe,  0x7077, 0x19);
    ov2718_write_register(ViPipe,  0x7078, 0xc1);
    ov2718_write_register(ViPipe,  0x7079, 0x3f);
    ov2718_write_register(ViPipe,  0x707a, 0xc3);
    ov2718_write_register(ViPipe,  0x707b, 0xaf);
    ov2718_write_register(ViPipe,  0x707c, 0xc0);
    ov2718_write_register(ViPipe,  0x707d, 0x41);
    ov2718_write_register(ViPipe,  0x707e, 0xc3);
    ov2718_write_register(ViPipe,  0x707f, 0xbe);
    ov2718_write_register(ViPipe,  0x7080, 0xe7);
    ov2718_write_register(ViPipe,  0x7081, 0x00);
    ov2718_write_register(ViPipe,  0x7082, 0x15);
    ov2718_write_register(ViPipe,  0x7083, 0xc2);
    ov2718_write_register(ViPipe,  0x7084, 0x45);
    ov2718_write_register(ViPipe,  0x7085, 0xc3);
    ov2718_write_register(ViPipe,  0x7086, 0xa6);
    ov2718_write_register(ViPipe,  0x7087, 0xc0);
    ov2718_write_register(ViPipe,  0x7088, 0x41);
    ov2718_write_register(ViPipe,  0x7089, 0x00);
    ov2718_write_register(ViPipe,  0x708a, 0x00);
    ov2718_write_register(ViPipe,  0x708b, 0x00);
    ov2718_write_register(ViPipe,  0x708c, 0xb9);
    ov2718_write_register(ViPipe,  0x708d, 0x64);
    ov2718_write_register(ViPipe,  0x708e, 0x29);
    ov2718_write_register(ViPipe,  0x708f, 0x00);
    ov2718_write_register(ViPipe,  0x7090, 0xb8);
    ov2718_write_register(ViPipe,  0x7091, 0x12);
    ov2718_write_register(ViPipe,  0x7092, 0xbe);
    ov2718_write_register(ViPipe,  0x7093, 0x01);
    ov2718_write_register(ViPipe,  0x7094, 0xd0);
    ov2718_write_register(ViPipe,  0x7095, 0xbc);
    ov2718_write_register(ViPipe,  0x7096, 0x01);
    ov2718_write_register(ViPipe,  0x7097, 0xac);
    ov2718_write_register(ViPipe,  0x7098, 0x37);
    ov2718_write_register(ViPipe,  0x7099, 0xd2);
    ov2718_write_register(ViPipe,  0x709a, 0xac);
    ov2718_write_register(ViPipe,  0x709b, 0xad);
    ov2718_write_register(ViPipe,  0x709c, 0x28);
    ov2718_write_register(ViPipe,  0x709d, 0x00);
    ov2718_write_register(ViPipe,  0x709e, 0xb8);
    ov2718_write_register(ViPipe,  0x709f, 0x00);
    ov2718_write_register(ViPipe,  0x70a0, 0xbc);
    ov2718_write_register(ViPipe,  0x70a1, 0x01);
    ov2718_write_register(ViPipe,  0x70a2, 0x36);
    ov2718_write_register(ViPipe,  0x70a3, 0xd3);
    ov2718_write_register(ViPipe,  0x70a4, 0x30);
    ov2718_write_register(ViPipe,  0x70a5, 0x04);
    ov2718_write_register(ViPipe,  0x70a6, 0xe0);
    ov2718_write_register(ViPipe,  0x70a7, 0xd8);
    ov2718_write_register(ViPipe,  0x70a8, 0xb4);
    ov2718_write_register(ViPipe,  0x70a9, 0xcd);
    ov2718_write_register(ViPipe,  0x70aa, 0x45);
    ov2718_write_register(ViPipe,  0x70ab, 0x00);
    ov2718_write_register(ViPipe,  0x70ac, 0xbe);
    ov2718_write_register(ViPipe,  0x70ad, 0x05);
    ov2718_write_register(ViPipe,  0x70ae, 0xbc);
    ov2718_write_register(ViPipe,  0x70af, 0x1e);
    ov2718_write_register(ViPipe,  0x70b0, 0x62);
    ov2718_write_register(ViPipe,  0x70b1, 0x07);
    ov2718_write_register(ViPipe,  0x70b2, 0xb9);
    ov2718_write_register(ViPipe,  0x70b3, 0x05);
    ov2718_write_register(ViPipe,  0x70b4, 0xad);
    ov2718_write_register(ViPipe,  0x70b5, 0xc3);
    ov2718_write_register(ViPipe,  0x70b6, 0xcd);
    ov2718_write_register(ViPipe,  0x70b7, 0x00);
    ov2718_write_register(ViPipe,  0x70b8, 0x15);
    ov2718_write_register(ViPipe,  0x70b9, 0xc2);
    ov2718_write_register(ViPipe,  0x70ba, 0x60);
    ov2718_write_register(ViPipe,  0x70bb, 0xc3);
    ov2718_write_register(ViPipe,  0x70bc, 0xc9);
    ov2718_write_register(ViPipe,  0x70bd, 0xc0);
    ov2718_write_register(ViPipe,  0x70be, 0x5c);
    ov2718_write_register(ViPipe,  0x70bf, 0x00);
    ov2718_write_register(ViPipe,  0x70c0, 0x46);
    ov2718_write_register(ViPipe,  0x70c1, 0x00);
    ov2718_write_register(ViPipe,  0x70c2, 0x00);
    ov2718_write_register(ViPipe,  0x70c3, 0xa1);
    ov2718_write_register(ViPipe,  0x70c4, 0xb9);
    ov2718_write_register(ViPipe,  0x70c5, 0x64);
    ov2718_write_register(ViPipe,  0x70c6, 0x29);
    ov2718_write_register(ViPipe,  0x70c7, 0x00);
    ov2718_write_register(ViPipe,  0x70c8, 0xb8);
    ov2718_write_register(ViPipe,  0x70c9, 0x02);
    ov2718_write_register(ViPipe,  0x70ca, 0xbe);
    ov2718_write_register(ViPipe,  0x70cb, 0x02);
    ov2718_write_register(ViPipe,  0x70cc, 0xd0);
    ov2718_write_register(ViPipe,  0x70cd, 0xdc);
    ov2718_write_register(ViPipe,  0x70ce, 0xac);
    ov2718_write_register(ViPipe,  0x70cf, 0xbc);
    ov2718_write_register(ViPipe,  0x70d0, 0x01);
    ov2718_write_register(ViPipe,  0x70d1, 0x37);
    ov2718_write_register(ViPipe,  0x70d2, 0xac);
    ov2718_write_register(ViPipe,  0x70d3, 0xd2);
    ov2718_write_register(ViPipe,  0x70d4, 0xad);
    ov2718_write_register(ViPipe,  0x70d5, 0x28);
    ov2718_write_register(ViPipe,  0x70d6, 0x00);
    ov2718_write_register(ViPipe,  0x70d7, 0xb8);
    ov2718_write_register(ViPipe,  0x70d8, 0x00);
    ov2718_write_register(ViPipe,  0x70d9, 0xbc);
    ov2718_write_register(ViPipe,  0x70da, 0x01);
    ov2718_write_register(ViPipe,  0x70db, 0x36);
    ov2718_write_register(ViPipe,  0x70dc, 0x30);
    ov2718_write_register(ViPipe,  0x70dd, 0xe0);
    ov2718_write_register(ViPipe,  0x70de, 0xd8);
    ov2718_write_register(ViPipe,  0x70df, 0xb5);
    ov2718_write_register(ViPipe,  0x70e0, 0x06);
    ov2718_write_register(ViPipe,  0x70e1, 0x45);
    ov2718_write_register(ViPipe,  0x70e2, 0xd6);
    ov2718_write_register(ViPipe,  0x70e3, 0xbe);
    ov2718_write_register(ViPipe,  0x70e4, 0x07);
    ov2718_write_register(ViPipe,  0x70e5, 0x00);
    ov2718_write_register(ViPipe,  0x70e6, 0x62);
    ov2718_write_register(ViPipe,  0x70e7, 0x07);
    ov2718_write_register(ViPipe,  0x70e8, 0xb9);
    ov2718_write_register(ViPipe,  0x70e9, 0x05);
    ov2718_write_register(ViPipe,  0x70ea, 0xad);
    ov2718_write_register(ViPipe,  0x70eb, 0xc3);
    ov2718_write_register(ViPipe,  0x70ec, 0xcd);
    ov2718_write_register(ViPipe,  0x70ed, 0x46);
    ov2718_write_register(ViPipe,  0x70ee, 0xcd);
    ov2718_write_register(ViPipe,  0x70ef, 0x07);
    ov2718_write_register(ViPipe,  0x70f0, 0xcd);
    ov2718_write_register(ViPipe,  0x70f1, 0x00);
    ov2718_write_register(ViPipe,  0x70f2, 0xe3);
    ov2718_write_register(ViPipe,  0x70f3, 0x18);
    ov2718_write_register(ViPipe,  0x70f4, 0xc2);
    ov2718_write_register(ViPipe,  0x70f5, 0xa9);
    ov2718_write_register(ViPipe,  0x70f6, 0xb9);
    ov2718_write_register(ViPipe,  0x70f7, 0x64);
    ov2718_write_register(ViPipe,  0x70f8, 0xd1);
    ov2718_write_register(ViPipe,  0x70f9, 0x50);
    ov2718_write_register(ViPipe,  0x70fa, 0xdd);
    ov2718_write_register(ViPipe,  0x70fb, 0xac);
    ov2718_write_register(ViPipe,  0x70fc, 0xcf);
    ov2718_write_register(ViPipe,  0x70fd, 0xdf);
    ov2718_write_register(ViPipe,  0x70fe, 0xb6);
    ov2718_write_register(ViPipe,  0x70ff, 0xee);
    ov2718_write_register(ViPipe,  0x7100, 0xbc);
    ov2718_write_register(ViPipe,  0x7101, 0x13);
    ov2718_write_register(ViPipe,  0x7102, 0xe1);
    ov2718_write_register(ViPipe,  0x7103, 0x36);
    ov2718_write_register(ViPipe,  0x7104, 0x30);
    ov2718_write_register(ViPipe,  0x7105, 0xd3);
    ov2718_write_register(ViPipe,  0x7106, 0x2e);
    ov2718_write_register(ViPipe,  0x7107, 0x54);
    ov2718_write_register(ViPipe,  0x7108, 0xbc);
    ov2718_write_register(ViPipe,  0x7109, 0x32);
    ov2718_write_register(ViPipe,  0x710a, 0x2c);
    ov2718_write_register(ViPipe,  0x710b, 0x50);
    ov2718_write_register(ViPipe,  0x710c, 0x20);
    ov2718_write_register(ViPipe,  0x710d, 0x04);
    ov2718_write_register(ViPipe,  0x710e, 0xb8);
    ov2718_write_register(ViPipe,  0x710f, 0x02);
    ov2718_write_register(ViPipe,  0x7110, 0xbc);
    ov2718_write_register(ViPipe,  0x7111, 0x18);
    ov2718_write_register(ViPipe,  0x7112, 0xc7);
    ov2718_write_register(ViPipe,  0x7113, 0xb8);
    ov2718_write_register(ViPipe,  0x7114, 0x00);
    ov2718_write_register(ViPipe,  0x7115, 0x28);
    ov2718_write_register(ViPipe,  0x7116, 0x54);
    ov2718_write_register(ViPipe,  0x7117, 0xb4);
    ov2718_write_register(ViPipe,  0x7118, 0xbf);
    ov2718_write_register(ViPipe,  0x7119, 0x46);
    ov2718_write_register(ViPipe,  0x711a, 0xbe);
    ov2718_write_register(ViPipe,  0x711b, 0x04);
    ov2718_write_register(ViPipe,  0x711c, 0xd6);
    ov2718_write_register(ViPipe,  0x711d, 0xd8);
    ov2718_write_register(ViPipe,  0x711e, 0xab);
    ov2718_write_register(ViPipe,  0x711f, 0x00);
    ov2718_write_register(ViPipe,  0x7120, 0x62);
    ov2718_write_register(ViPipe,  0x7121, 0x07);
    ov2718_write_register(ViPipe,  0x7122, 0xb9);
    ov2718_write_register(ViPipe,  0x7123, 0x05);
    ov2718_write_register(ViPipe,  0x7124, 0xad);
    ov2718_write_register(ViPipe,  0x7125, 0xc3);
    ov2718_write_register(ViPipe,  0x7126, 0xad);
    ov2718_write_register(ViPipe,  0x7127, 0xb9);
    ov2718_write_register(ViPipe,  0x7128, 0x64);
    ov2718_write_register(ViPipe,  0x7129, 0x29);
    ov2718_write_register(ViPipe,  0x712a, 0x00);
    ov2718_write_register(ViPipe,  0x712b, 0xb8);
    ov2718_write_register(ViPipe,  0x712c, 0x02);
    ov2718_write_register(ViPipe,  0x712d, 0xbe);
    ov2718_write_register(ViPipe,  0x712e, 0x00);
    ov2718_write_register(ViPipe,  0x712f, 0xad);
    ov2718_write_register(ViPipe,  0x7130, 0xe2);
    ov2718_write_register(ViPipe,  0x7131, 0x28);
    ov2718_write_register(ViPipe,  0x7132, 0x00);
    ov2718_write_register(ViPipe,  0x7133, 0xb8);
    ov2718_write_register(ViPipe,  0x7134, 0x00);
    ov2718_write_register(ViPipe,  0x7135, 0xe6);
    ov2718_write_register(ViPipe,  0x7136, 0xbd);
    ov2718_write_register(ViPipe,  0x7137, 0x03);
    ov2718_write_register(ViPipe,  0x7138, 0xec);
    ov2718_write_register(ViPipe,  0x7139, 0xe0);
    ov2718_write_register(ViPipe,  0x713a, 0xd8);
    ov2718_write_register(ViPipe,  0x713b, 0xb4);
    ov2718_write_register(ViPipe,  0x713c, 0xcd);
    ov2718_write_register(ViPipe,  0x713d, 0x45);
    ov2718_write_register(ViPipe,  0x713e, 0xbe);
    ov2718_write_register(ViPipe,  0x713f, 0x03);
    ov2718_write_register(ViPipe,  0x7140, 0x00);
    ov2718_write_register(ViPipe,  0x7141, 0x30);
    ov2718_write_register(ViPipe,  0x7142, 0xbc);
    ov2718_write_register(ViPipe,  0x7143, 0x1c);
    ov2718_write_register(ViPipe,  0x7144, 0x62);
    ov2718_write_register(ViPipe,  0x7145, 0x07);
    ov2718_write_register(ViPipe,  0x7146, 0xb9);
    ov2718_write_register(ViPipe,  0x7147, 0x05);
    ov2718_write_register(ViPipe,  0x7148, 0xad);
    ov2718_write_register(ViPipe,  0x7149, 0xc3);
    ov2718_write_register(ViPipe,  0x714a, 0xcd);
    ov2718_write_register(ViPipe,  0x714b, 0x42);
    ov2718_write_register(ViPipe,  0x714c, 0xe4);
    ov2718_write_register(ViPipe,  0x714d, 0xcd);
    ov2718_write_register(ViPipe,  0x714e, 0x07);
    ov2718_write_register(ViPipe,  0x714f, 0xcd);
    ov2718_write_register(ViPipe,  0x7150, 0x00);
    ov2718_write_register(ViPipe,  0x7151, 0x00);
    ov2718_write_register(ViPipe,  0x7152, 0x17);
    ov2718_write_register(ViPipe,  0x7153, 0xc2);
    ov2718_write_register(ViPipe,  0x7154, 0xc2);
    ov2718_write_register(ViPipe,  0x7155, 0xde);
    ov2718_write_register(ViPipe,  0x7156, 0xcf);
    ov2718_write_register(ViPipe,  0x7157, 0xdf);
    ov2718_write_register(ViPipe,  0x7158, 0xac);
    ov2718_write_register(ViPipe,  0x7159, 0xd1);
    ov2718_write_register(ViPipe,  0x715a, 0x44);
    ov2718_write_register(ViPipe,  0x715b, 0xac);
    ov2718_write_register(ViPipe,  0x715c, 0xb9);
    ov2718_write_register(ViPipe,  0x715d, 0x76);
    ov2718_write_register(ViPipe,  0x715e, 0xb8);
    ov2718_write_register(ViPipe,  0x715f, 0x08);
    ov2718_write_register(ViPipe,  0x7160, 0xb6);
    ov2718_write_register(ViPipe,  0x7161, 0xfe);
    ov2718_write_register(ViPipe,  0x7162, 0xb4);
    ov2718_write_register(ViPipe,  0x7163, 0xbf);
    ov2718_write_register(ViPipe,  0x7164, 0xd6);
    ov2718_write_register(ViPipe,  0x7165, 0xd8);
    ov2718_write_register(ViPipe,  0x7166, 0xab);
    ov2718_write_register(ViPipe,  0x7167, 0x00);
    ov2718_write_register(ViPipe,  0x7168, 0xe1);
    ov2718_write_register(ViPipe,  0x7169, 0x36);
    ov2718_write_register(ViPipe,  0x716a, 0x30);
    ov2718_write_register(ViPipe,  0x716b, 0xd3);
    ov2718_write_register(ViPipe,  0x716c, 0xbc);
    ov2718_write_register(ViPipe,  0x716d, 0x29);
    ov2718_write_register(ViPipe,  0x716e, 0xb4);
    ov2718_write_register(ViPipe,  0x716f, 0x1d);
    ov2718_write_register(ViPipe,  0x7170, 0xaa);
    ov2718_write_register(ViPipe,  0x7171, 0xbd);
    ov2718_write_register(ViPipe,  0x7172, 0x01);
    ov2718_write_register(ViPipe,  0x7173, 0xb8);
    ov2718_write_register(ViPipe,  0x7174, 0x0c);
    ov2718_write_register(ViPipe,  0x7175, 0x45);
    ov2718_write_register(ViPipe,  0x7176, 0xe6);
    ov2718_write_register(ViPipe,  0x7177, 0xbd);
    ov2718_write_register(ViPipe,  0x7178, 0x03);
    ov2718_write_register(ViPipe,  0x7179, 0xec);
    ov2718_write_register(ViPipe,  0x717a, 0xbc);
    ov2718_write_register(ViPipe,  0x717b, 0x3d);
    ov2718_write_register(ViPipe,  0x717c, 0xc3);
    ov2718_write_register(ViPipe,  0x717d, 0xcd);
    ov2718_write_register(ViPipe,  0x717e, 0x42);
    ov2718_write_register(ViPipe,  0x717f, 0xb8);
    ov2718_write_register(ViPipe,  0x7180, 0x00);
    ov2718_write_register(ViPipe,  0x7181, 0xe4);
    ov2718_write_register(ViPipe,  0x7182, 0xd5);
    ov2718_write_register(ViPipe,  0x7183, 0x00);
    ov2718_write_register(ViPipe,  0x7184, 0xb6);
    ov2718_write_register(ViPipe,  0x7185, 0x00);
    ov2718_write_register(ViPipe,  0x7186, 0xbd);
    ov2718_write_register(ViPipe,  0x7187, 0x03);
    ov2718_write_register(ViPipe,  0x7188, 0xb5);
    ov2718_write_register(ViPipe,  0x7189, 0x4b);
    ov2718_write_register(ViPipe,  0x718a, 0x40);
    ov2718_write_register(ViPipe,  0x718b, 0x58);
    ov2718_write_register(ViPipe,  0x718c, 0x6a);
    ov2718_write_register(ViPipe,  0x718d, 0xdd);
    ov2718_write_register(ViPipe,  0x718e, 0x19);
    ov2718_write_register(ViPipe,  0x718f, 0xc1);
    ov2718_write_register(ViPipe,  0x7190, 0xc9);
    ov2718_write_register(ViPipe,  0x7191, 0xe8);
    ov2718_write_register(ViPipe,  0x7192, 0xbc);
    ov2718_write_register(ViPipe,  0x7193, 0x19);
    ov2718_write_register(ViPipe,  0x7194, 0xb9);
    ov2718_write_register(ViPipe,  0x7195, 0xf6);
    ov2718_write_register(ViPipe,  0x7196, 0x14);
    ov2718_write_register(ViPipe,  0x7197, 0xc1);
    ov2718_write_register(ViPipe,  0x7198, 0xd1);
    ov2718_write_register(ViPipe,  0x7199, 0xd1);
    ov2718_write_register(ViPipe,  0x719a, 0xac);
    ov2718_write_register(ViPipe,  0x719b, 0x37);
    ov2718_write_register(ViPipe,  0x719c, 0xbc);
    ov2718_write_register(ViPipe,  0x719d, 0x35);
    ov2718_write_register(ViPipe,  0x719e, 0x36);
    ov2718_write_register(ViPipe,  0x719f, 0x30);
    ov2718_write_register(ViPipe,  0x71a0, 0xe1);
    ov2718_write_register(ViPipe,  0x71a1, 0xd3);
    ov2718_write_register(ViPipe,  0x71a2, 0x7a);
    ov2718_write_register(ViPipe,  0x71a3, 0xb6);
    ov2718_write_register(ViPipe,  0x71a4, 0x0c);
    ov2718_write_register(ViPipe,  0x71a5, 0xff);
    ov2718_write_register(ViPipe,  0x71a6, 0xb4);
    ov2718_write_register(ViPipe,  0x71a7, 0xbc);
    ov2718_write_register(ViPipe,  0x71a8, 0xd9);
    ov2718_write_register(ViPipe,  0x71a9, 0x00);
    ov2718_write_register(ViPipe,  0x71aa, 0x56);
    ov2718_write_register(ViPipe,  0x71ab, 0xc0);
    ov2718_write_register(ViPipe,  0x71ac, 0xda);
    ov2718_write_register(ViPipe,  0x71ad, 0xb4);
    ov2718_write_register(ViPipe,  0x71ae, 0x1d);
    ov2718_write_register(ViPipe,  0x71af, 0x56);
    ov2718_write_register(ViPipe,  0x71b0, 0xaa);
    ov2718_write_register(ViPipe,  0x71b1, 0xbc);
    ov2718_write_register(ViPipe,  0x71b2, 0x08);
    ov2718_write_register(ViPipe,  0x71b3, 0x00);
    ov2718_write_register(ViPipe,  0x71b4, 0x57);
    ov2718_write_register(ViPipe,  0x71b5, 0xe8);
    ov2718_write_register(ViPipe,  0x71b6, 0xb5);
    ov2718_write_register(ViPipe,  0x71b7, 0x48);
    ov2718_write_register(ViPipe,  0x71b8, 0x00);
    ov2718_write_register(ViPipe,  0x71b9, 0x54);
    ov2718_write_register(ViPipe,  0x71ba, 0xe7);
    ov2718_write_register(ViPipe,  0x71bb, 0xc8);
    ov2718_write_register(ViPipe,  0x71bc, 0xb4);
    ov2718_write_register(ViPipe,  0x71bd, 0x1d);
    ov2718_write_register(ViPipe,  0x71be, 0x56);
    ov2718_write_register(ViPipe,  0x71bf, 0xaa);
    ov2718_write_register(ViPipe,  0x71c0, 0xbc);
    ov2718_write_register(ViPipe,  0x71c1, 0x08);
    ov2718_write_register(ViPipe,  0x71c2, 0x57);
    ov2718_write_register(ViPipe,  0x71c3, 0x00);
    ov2718_write_register(ViPipe,  0x71c4, 0xb5);
    ov2718_write_register(ViPipe,  0x71c5, 0x48);
    ov2718_write_register(ViPipe,  0x71c6, 0x00);
    ov2718_write_register(ViPipe,  0x71c7, 0x54);
    ov2718_write_register(ViPipe,  0x71c8, 0xc8);
    ov2718_write_register(ViPipe,  0x71c9, 0xb5);
    ov2718_write_register(ViPipe,  0x71ca, 0x14);
    ov2718_write_register(ViPipe,  0x71cb, 0xd9);
    ov2718_write_register(ViPipe,  0x71cc, 0x00);
    ov2718_write_register(ViPipe,  0x71cd, 0x56);
    ov2718_write_register(ViPipe,  0x71ce, 0x08);
    ov2718_write_register(ViPipe,  0x71cf, 0x57);
    ov2718_write_register(ViPipe,  0x71d0, 0xe8);
    ov2718_write_register(ViPipe,  0x71d1, 0xb4);
    ov2718_write_register(ViPipe,  0x71d2, 0x44);
    ov2718_write_register(ViPipe,  0x71d3, 0x00);
    ov2718_write_register(ViPipe,  0x71d4, 0x54);
    ov2718_write_register(ViPipe,  0x71d5, 0xe7);
    ov2718_write_register(ViPipe,  0x71d6, 0xc8);
    ov2718_write_register(ViPipe,  0x71d7, 0xab);
    ov2718_write_register(ViPipe,  0x71d8, 0x00);
    ov2718_write_register(ViPipe,  0x71d9, 0x66);
    ov2718_write_register(ViPipe,  0x71da, 0x62);
    ov2718_write_register(ViPipe,  0x71db, 0x06);
    ov2718_write_register(ViPipe,  0x71dc, 0x74);
    ov2718_write_register(ViPipe,  0x71dd, 0xb9);
    ov2718_write_register(ViPipe,  0x71de, 0x05);
    ov2718_write_register(ViPipe,  0x71df, 0xb7);
    ov2718_write_register(ViPipe,  0x71e0, 0x10);
    ov2718_write_register(ViPipe,  0x71e1, 0x0e);
    ov2718_write_register(ViPipe,  0x71e2, 0xb7);
    ov2718_write_register(ViPipe,  0x71e3, 0x04);
    ov2718_write_register(ViPipe,  0x71e4, 0xc8);
    ov2718_write_register(ViPipe,  0x7600, 0x04);
    ov2718_write_register(ViPipe,  0x7601, 0x80);
    ov2718_write_register(ViPipe,  0x7602, 0x07);
    ov2718_write_register(ViPipe,  0x7603, 0x44);
    ov2718_write_register(ViPipe,  0x7604, 0x05);
    ov2718_write_register(ViPipe,  0x7605, 0x33);
    ov2718_write_register(ViPipe,  0x7606, 0x0f);
    ov2718_write_register(ViPipe,  0x7607, 0x00);
    ov2718_write_register(ViPipe,  0x7608, 0x07);
    ov2718_write_register(ViPipe,  0x7609, 0x40);
    ov2718_write_register(ViPipe,  0x760a, 0x04);
    ov2718_write_register(ViPipe,  0x760b, 0xe5);
    ov2718_write_register(ViPipe,  0x760c, 0x06);
    ov2718_write_register(ViPipe,  0x760d, 0x50);
    ov2718_write_register(ViPipe,  0x760e, 0x04);
    ov2718_write_register(ViPipe,  0x760f, 0xe4);
    ov2718_write_register(ViPipe,  0x7610, 0x00);
    ov2718_write_register(ViPipe,  0x7611, 0x00);
    ov2718_write_register(ViPipe,  0x7612, 0x06);
    ov2718_write_register(ViPipe,  0x7613, 0x5c);
    ov2718_write_register(ViPipe,  0x7614, 0x00);
    ov2718_write_register(ViPipe,  0x7615, 0x0f);
    ov2718_write_register(ViPipe,  0x7616, 0x06);
    ov2718_write_register(ViPipe,  0x7617, 0x1c);
    ov2718_write_register(ViPipe,  0x7618, 0x00);
    ov2718_write_register(ViPipe,  0x7619, 0x02);
    ov2718_write_register(ViPipe,  0x761a, 0x06);
    ov2718_write_register(ViPipe,  0x761b, 0xa0);
    ov2718_write_register(ViPipe,  0x761c, 0x00);
    ov2718_write_register(ViPipe,  0x761d, 0x01);
    ov2718_write_register(ViPipe,  0x761e, 0x06);
    ov2718_write_register(ViPipe,  0x761f, 0xac);
    ov2718_write_register(ViPipe,  0x7620, 0x00);
    ov2718_write_register(ViPipe,  0x7621, 0x0f);
    ov2718_write_register(ViPipe,  0x7622, 0x05);
    ov2718_write_register(ViPipe,  0x7623, 0x30);
    ov2718_write_register(ViPipe,  0x7624, 0x07);
    ov2718_write_register(ViPipe,  0x7625, 0x00);
    ov2718_write_register(ViPipe,  0x7626, 0x0f);
    ov2718_write_register(ViPipe,  0x7627, 0x00);
    ov2718_write_register(ViPipe,  0x7628, 0x04);
    ov2718_write_register(ViPipe,  0x7629, 0xe5);
    ov2718_write_register(ViPipe,  0x762a, 0x05);
    ov2718_write_register(ViPipe,  0x762b, 0x33);
    ov2718_write_register(ViPipe,  0x762c, 0x06);
    ov2718_write_register(ViPipe,  0x762d, 0x50);
    ov2718_write_register(ViPipe,  0x762e, 0x00);
    ov2718_write_register(ViPipe,  0x762f, 0x01);
    ov2718_write_register(ViPipe,  0x7630, 0x06);
    ov2718_write_register(ViPipe,  0x7631, 0x5c);
    ov2718_write_register(ViPipe,  0x7632, 0x04);
    ov2718_write_register(ViPipe,  0x7633, 0xe4);
    ov2718_write_register(ViPipe,  0x7634, 0x00);
    ov2718_write_register(ViPipe,  0x7635, 0x0e);
    ov2718_write_register(ViPipe,  0x7636, 0x05);
    ov2718_write_register(ViPipe,  0x7637, 0x30);
    ov2718_write_register(ViPipe,  0x7638, 0x0f);
    ov2718_write_register(ViPipe,  0x7639, 0x00);
    ov2718_write_register(ViPipe,  0x763a, 0x06);
    ov2718_write_register(ViPipe,  0x763b, 0x24);
    ov2718_write_register(ViPipe,  0x763c, 0x00);
    ov2718_write_register(ViPipe,  0x763d, 0x03);
    ov2718_write_register(ViPipe,  0x763e, 0x05);
    ov2718_write_register(ViPipe,  0x763f, 0x33);
    ov2718_write_register(ViPipe,  0x7640, 0x07);
    ov2718_write_register(ViPipe,  0x7641, 0x02);
    ov2718_write_register(ViPipe,  0x7642, 0x06);
    ov2718_write_register(ViPipe,  0x7643, 0x24);
    ov2718_write_register(ViPipe,  0x7644, 0x00);
    ov2718_write_register(ViPipe,  0x7645, 0x01);
    ov2718_write_register(ViPipe,  0x7646, 0x06);
    ov2718_write_register(ViPipe,  0x7647, 0x20);
    ov2718_write_register(ViPipe,  0x7648, 0x0f);
    ov2718_write_register(ViPipe,  0x7649, 0x00);
    ov2718_write_register(ViPipe,  0x764a, 0x06);
    ov2718_write_register(ViPipe,  0x764b, 0x14);
    ov2718_write_register(ViPipe,  0x764c, 0x00);
    ov2718_write_register(ViPipe,  0x764d, 0x03);
    ov2718_write_register(ViPipe,  0x764e, 0x05);
    ov2718_write_register(ViPipe,  0x764f, 0x33);
    ov2718_write_register(ViPipe,  0x7650, 0x07);
    ov2718_write_register(ViPipe,  0x7651, 0x02);
    ov2718_write_register(ViPipe,  0x7652, 0x06);
    ov2718_write_register(ViPipe,  0x7653, 0x14);
    ov2718_write_register(ViPipe,  0x7654, 0x00);
    ov2718_write_register(ViPipe,  0x7655, 0x01);
    ov2718_write_register(ViPipe,  0x7656, 0x06);
    ov2718_write_register(ViPipe,  0x7657, 0x10);
    ov2718_write_register(ViPipe,  0x7658, 0x0f);
    ov2718_write_register(ViPipe,  0x7659, 0x00);
    ov2718_write_register(ViPipe,  0x765a, 0x06);
    ov2718_write_register(ViPipe,  0x765b, 0x10);
    ov2718_write_register(ViPipe,  0x765c, 0x0f);
    ov2718_write_register(ViPipe,  0x765d, 0x00);
    ov2718_write_register(ViPipe,  0x765e, 0x06);
    ov2718_write_register(ViPipe,  0x765f, 0x20);
    ov2718_write_register(ViPipe,  0x7660, 0x0f);
    ov2718_write_register(ViPipe,  0x7661, 0x00);
    ov2718_write_register(ViPipe,  0x7662, 0x00);
    ov2718_write_register(ViPipe,  0x7663, 0x00);
    ov2718_write_register(ViPipe,  0x7664, 0x00);
    ov2718_write_register(ViPipe,  0x7665, 0x02);
    ov2718_write_register(ViPipe,  0x7666, 0x04);
    ov2718_write_register(ViPipe,  0x7667, 0xe5);
    ov2718_write_register(ViPipe,  0x7668, 0x04);
    ov2718_write_register(ViPipe,  0x7669, 0xe4);
    ov2718_write_register(ViPipe,  0x766a, 0x0f);
    ov2718_write_register(ViPipe,  0x766b, 0x00);
    ov2718_write_register(ViPipe,  0x766c, 0x00);
    ov2718_write_register(ViPipe,  0x766d, 0x00);
    ov2718_write_register(ViPipe,  0x766e, 0x00);
    ov2718_write_register(ViPipe,  0x766f, 0x02);
    ov2718_write_register(ViPipe,  0x7670, 0x04);
    ov2718_write_register(ViPipe,  0x7671, 0xe5);
    ov2718_write_register(ViPipe,  0x7672, 0x04);
    ov2718_write_register(ViPipe,  0x7673, 0xe4);
    ov2718_write_register(ViPipe,  0x7674, 0x0f);
    ov2718_write_register(ViPipe,  0x7675, 0x00);
    ov2718_write_register(ViPipe,  0x7676, 0x00);
    ov2718_write_register(ViPipe,  0x7677, 0x02);
    ov2718_write_register(ViPipe,  0x7678, 0x04);
    ov2718_write_register(ViPipe,  0x7679, 0xe4);
    ov2718_write_register(ViPipe,  0x767a, 0x00);
    ov2718_write_register(ViPipe,  0x767b, 0x02);
    ov2718_write_register(ViPipe,  0x767c, 0x04);
    ov2718_write_register(ViPipe,  0x767d, 0xc4);
    ov2718_write_register(ViPipe,  0x767e, 0x00);
    ov2718_write_register(ViPipe,  0x767f, 0x04);
    ov2718_write_register(ViPipe,  0x7680, 0x04);
    ov2718_write_register(ViPipe,  0x7681, 0xc4);
    ov2718_write_register(ViPipe,  0x7682, 0x05);
    ov2718_write_register(ViPipe,  0x7683, 0x83);
    ov2718_write_register(ViPipe,  0x7684, 0x07);
    ov2718_write_register(ViPipe,  0x7685, 0x02);
    ov2718_write_register(ViPipe,  0x7686, 0x0f);
    ov2718_write_register(ViPipe,  0x7687, 0x00);
    ov2718_write_register(ViPipe,  0x7688, 0x00);
    ov2718_write_register(ViPipe,  0x7689, 0x02);
    ov2718_write_register(ViPipe,  0x768a, 0x04);
    ov2718_write_register(ViPipe,  0x768b, 0xe4);
    ov2718_write_register(ViPipe,  0x768c, 0x00);
    ov2718_write_register(ViPipe,  0x768d, 0x02);
    ov2718_write_register(ViPipe,  0x768e, 0x04);
    ov2718_write_register(ViPipe,  0x768f, 0xc4);
    ov2718_write_register(ViPipe,  0x7690, 0x00);
    ov2718_write_register(ViPipe,  0x7691, 0x04);
    ov2718_write_register(ViPipe,  0x7692, 0x04);
    ov2718_write_register(ViPipe,  0x7693, 0xc4);
    ov2718_write_register(ViPipe,  0x7694, 0x05);
    ov2718_write_register(ViPipe,  0x7695, 0x83);
    ov2718_write_register(ViPipe,  0x7696, 0x07);
    ov2718_write_register(ViPipe,  0x7697, 0x02);
    ov2718_write_register(ViPipe,  0x7698, 0x03);
    ov2718_write_register(ViPipe,  0x7699, 0x0b);
    ov2718_write_register(ViPipe,  0x769a, 0x05);
    ov2718_write_register(ViPipe,  0x769b, 0x83);
    ov2718_write_register(ViPipe,  0x769c, 0x00);
    ov2718_write_register(ViPipe,  0x769d, 0x08);
    ov2718_write_register(ViPipe,  0x769e, 0x05);
    ov2718_write_register(ViPipe,  0x769f, 0x03);
    ov2718_write_register(ViPipe,  0x76a0, 0x05);
    ov2718_write_register(ViPipe,  0x76a1, 0x32);
    ov2718_write_register(ViPipe,  0x76a2, 0x00);
    ov2718_write_register(ViPipe,  0x76a3, 0x00);
    ov2718_write_register(ViPipe,  0x76a4, 0x05);
    ov2718_write_register(ViPipe,  0x76a5, 0x70);
    ov2718_write_register(ViPipe,  0x76a6, 0x00);
    ov2718_write_register(ViPipe,  0x76a7, 0x01);
    ov2718_write_register(ViPipe,  0x76a8, 0x05);
    ov2718_write_register(ViPipe,  0x76a9, 0x74);
    ov2718_write_register(ViPipe,  0x76aa, 0x03);
    ov2718_write_register(ViPipe,  0x76ab, 0x9a);
    ov2718_write_register(ViPipe,  0x76ac, 0x05);
    ov2718_write_register(ViPipe,  0x76ad, 0x83);
    ov2718_write_register(ViPipe,  0x76ae, 0x00);
    ov2718_write_register(ViPipe,  0x76af, 0x05);
    ov2718_write_register(ViPipe,  0x76b0, 0x05);
    ov2718_write_register(ViPipe,  0x76b1, 0x03);
    ov2718_write_register(ViPipe,  0x76b2, 0x05);
    ov2718_write_register(ViPipe,  0x76b3, 0x32);
    ov2718_write_register(ViPipe,  0x76b4, 0x00);
    ov2718_write_register(ViPipe,  0x76b5, 0x00);
    ov2718_write_register(ViPipe,  0x76b6, 0x05);
    ov2718_write_register(ViPipe,  0x76b7, 0x70);
    ov2718_write_register(ViPipe,  0x76b8, 0x00);
    ov2718_write_register(ViPipe,  0x76b9, 0x01);
    ov2718_write_register(ViPipe,  0x76ba, 0x05);
    ov2718_write_register(ViPipe,  0x76bb, 0x74);
    ov2718_write_register(ViPipe,  0x76bc, 0x03);
    ov2718_write_register(ViPipe,  0x76bd, 0x99);
    ov2718_write_register(ViPipe,  0x76be, 0x05);
    ov2718_write_register(ViPipe,  0x76bf, 0x83);
    ov2718_write_register(ViPipe,  0x76c0, 0x00);
    ov2718_write_register(ViPipe,  0x76c1, 0x03);
    ov2718_write_register(ViPipe,  0x76c2, 0x05);
    ov2718_write_register(ViPipe,  0x76c3, 0x03);
    ov2718_write_register(ViPipe,  0x76c4, 0x05);
    ov2718_write_register(ViPipe,  0x76c5, 0x32);
    ov2718_write_register(ViPipe,  0x76c6, 0x00);
    ov2718_write_register(ViPipe,  0x76c7, 0x00);
    ov2718_write_register(ViPipe,  0x76c8, 0x05);
    ov2718_write_register(ViPipe,  0x76c9, 0x70);
    ov2718_write_register(ViPipe,  0x76ca, 0x00);
    ov2718_write_register(ViPipe,  0x76cb, 0x01);
    ov2718_write_register(ViPipe,  0x76cc, 0x05);
    ov2718_write_register(ViPipe,  0x76cd, 0x74);
    ov2718_write_register(ViPipe,  0x76ce, 0x03);
    ov2718_write_register(ViPipe,  0x76cf, 0x98);
    ov2718_write_register(ViPipe,  0x76d0, 0x05);
    ov2718_write_register(ViPipe,  0x76d1, 0x83);
    ov2718_write_register(ViPipe,  0x76d2, 0x00);
    ov2718_write_register(ViPipe,  0x76d3, 0x01);
    ov2718_write_register(ViPipe,  0x76d4, 0x05);
    ov2718_write_register(ViPipe,  0x76d5, 0x03);
    ov2718_write_register(ViPipe,  0x76d6, 0x05);
    ov2718_write_register(ViPipe,  0x76d7, 0x32);
    ov2718_write_register(ViPipe,  0x76d8, 0x00);
    ov2718_write_register(ViPipe,  0x76d9, 0x00);
    ov2718_write_register(ViPipe,  0x76da, 0x05);
    ov2718_write_register(ViPipe,  0x76db, 0x70);
    ov2718_write_register(ViPipe,  0x76dc, 0x00);
    ov2718_write_register(ViPipe,  0x76dd, 0x01);
    ov2718_write_register(ViPipe,  0x76de, 0x05);
    ov2718_write_register(ViPipe,  0x76df, 0x74);
    ov2718_write_register(ViPipe,  0x76e0, 0x03);
    ov2718_write_register(ViPipe,  0x76e1, 0x97);
    ov2718_write_register(ViPipe,  0x76e2, 0x05);
    ov2718_write_register(ViPipe,  0x76e3, 0x83);
    ov2718_write_register(ViPipe,  0x76e4, 0x00);
    ov2718_write_register(ViPipe,  0x76e5, 0x01);
    ov2718_write_register(ViPipe,  0x76e6, 0x05);
    ov2718_write_register(ViPipe,  0x76e7, 0x03);
    ov2718_write_register(ViPipe,  0x76e8, 0x05);
    ov2718_write_register(ViPipe,  0x76e9, 0x32);
    ov2718_write_register(ViPipe,  0x76ea, 0x00);
    ov2718_write_register(ViPipe,  0x76eb, 0x00);
    ov2718_write_register(ViPipe,  0x76ec, 0x05);
    ov2718_write_register(ViPipe,  0x76ed, 0x70);
    ov2718_write_register(ViPipe,  0x76ee, 0x00);
    ov2718_write_register(ViPipe,  0x76ef, 0x01);
    ov2718_write_register(ViPipe,  0x76f0, 0x05);
    ov2718_write_register(ViPipe,  0x76f1, 0x74);
    ov2718_write_register(ViPipe,  0x76f2, 0x03);
    ov2718_write_register(ViPipe,  0x76f3, 0x96);
    ov2718_write_register(ViPipe,  0x76f4, 0x05);
    ov2718_write_register(ViPipe,  0x76f5, 0x83);
    ov2718_write_register(ViPipe,  0x76f6, 0x00);
    ov2718_write_register(ViPipe,  0x76f7, 0x01);
    ov2718_write_register(ViPipe,  0x76f8, 0x05);
    ov2718_write_register(ViPipe,  0x76f9, 0x03);
    ov2718_write_register(ViPipe,  0x76fa, 0x05);
    ov2718_write_register(ViPipe,  0x76fb, 0x32);
    ov2718_write_register(ViPipe,  0x76fc, 0x00);
    ov2718_write_register(ViPipe,  0x76fd, 0x00);
    ov2718_write_register(ViPipe,  0x76fe, 0x05);
    ov2718_write_register(ViPipe,  0x76ff, 0x70);
    ov2718_write_register(ViPipe,  0x7700, 0x00);
    ov2718_write_register(ViPipe,  0x7701, 0x01);
    ov2718_write_register(ViPipe,  0x7702, 0x05);
    ov2718_write_register(ViPipe,  0x7703, 0x74);
    ov2718_write_register(ViPipe,  0x7704, 0x03);
    ov2718_write_register(ViPipe,  0x7705, 0x95);
    ov2718_write_register(ViPipe,  0x7706, 0x05);
    ov2718_write_register(ViPipe,  0x7707, 0x83);
    ov2718_write_register(ViPipe,  0x7708, 0x00);
    ov2718_write_register(ViPipe,  0x7709, 0x01);
    ov2718_write_register(ViPipe,  0x770a, 0x05);
    ov2718_write_register(ViPipe,  0x770b, 0x03);
    ov2718_write_register(ViPipe,  0x770c, 0x05);
    ov2718_write_register(ViPipe,  0x770d, 0x32);
    ov2718_write_register(ViPipe,  0x770e, 0x00);
    ov2718_write_register(ViPipe,  0x770f, 0x00);
    ov2718_write_register(ViPipe,  0x7710, 0x05);
    ov2718_write_register(ViPipe,  0x7711, 0x70);
    ov2718_write_register(ViPipe,  0x7712, 0x00);
    ov2718_write_register(ViPipe,  0x7713, 0x01);
    ov2718_write_register(ViPipe,  0x7714, 0x05);
    ov2718_write_register(ViPipe,  0x7715, 0x74);
    ov2718_write_register(ViPipe,  0x7716, 0x03);
    ov2718_write_register(ViPipe,  0x7717, 0x94);
    ov2718_write_register(ViPipe,  0x7718, 0x05);
    ov2718_write_register(ViPipe,  0x7719, 0x83);
    ov2718_write_register(ViPipe,  0x771a, 0x00);
    ov2718_write_register(ViPipe,  0x771b, 0x03);
    ov2718_write_register(ViPipe,  0x771c, 0x05);
    ov2718_write_register(ViPipe,  0x771d, 0x03);
    ov2718_write_register(ViPipe,  0x771e, 0x05);
    ov2718_write_register(ViPipe,  0x771f, 0x32);
    ov2718_write_register(ViPipe,  0x7720, 0x00);
    ov2718_write_register(ViPipe,  0x7721, 0x00);
    ov2718_write_register(ViPipe,  0x7722, 0x05);
    ov2718_write_register(ViPipe,  0x7723, 0x70);
    ov2718_write_register(ViPipe,  0x7724, 0x00);
    ov2718_write_register(ViPipe,  0x7725, 0x01);
    ov2718_write_register(ViPipe,  0x7726, 0x05);
    ov2718_write_register(ViPipe,  0x7727, 0x74);
    ov2718_write_register(ViPipe,  0x7728, 0x03);
    ov2718_write_register(ViPipe,  0x7729, 0x93);
    ov2718_write_register(ViPipe,  0x772a, 0x05);
    ov2718_write_register(ViPipe,  0x772b, 0x83);
    ov2718_write_register(ViPipe,  0x772c, 0x00);
    ov2718_write_register(ViPipe,  0x772d, 0x02);
    ov2718_write_register(ViPipe,  0x772e, 0x05);
    ov2718_write_register(ViPipe,  0x772f, 0x03);
    ov2718_write_register(ViPipe,  0x7730, 0x05);
    ov2718_write_register(ViPipe,  0x7731, 0x32);
    ov2718_write_register(ViPipe,  0x7732, 0x00);
    ov2718_write_register(ViPipe,  0x7733, 0x00);
    ov2718_write_register(ViPipe,  0x7734, 0x05);
    ov2718_write_register(ViPipe,  0x7735, 0x70);
    ov2718_write_register(ViPipe,  0x7736, 0x00);
    ov2718_write_register(ViPipe,  0x7737, 0x01);
    ov2718_write_register(ViPipe,  0x7738, 0x05);
    ov2718_write_register(ViPipe,  0x7739, 0x74);
    ov2718_write_register(ViPipe,  0x773a, 0x03);
    ov2718_write_register(ViPipe,  0x773b, 0x92);
    ov2718_write_register(ViPipe,  0x773c, 0x05);
    ov2718_write_register(ViPipe,  0x773d, 0x83);
    ov2718_write_register(ViPipe,  0x773e, 0x00);
    ov2718_write_register(ViPipe,  0x773f, 0x01);
    ov2718_write_register(ViPipe,  0x7740, 0x05);
    ov2718_write_register(ViPipe,  0x7741, 0x03);
    ov2718_write_register(ViPipe,  0x7742, 0x05);
    ov2718_write_register(ViPipe,  0x7743, 0x32);
    ov2718_write_register(ViPipe,  0x7744, 0x00);
    ov2718_write_register(ViPipe,  0x7745, 0x00);
    ov2718_write_register(ViPipe,  0x7746, 0x05);
    ov2718_write_register(ViPipe,  0x7747, 0x70);
    ov2718_write_register(ViPipe,  0x7748, 0x00);
    ov2718_write_register(ViPipe,  0x7749, 0x01);
    ov2718_write_register(ViPipe,  0x774a, 0x05);
    ov2718_write_register(ViPipe,  0x774b, 0x74);
    ov2718_write_register(ViPipe,  0x774c, 0x03);
    ov2718_write_register(ViPipe,  0x774d, 0x91);
    ov2718_write_register(ViPipe,  0x774e, 0x05);
    ov2718_write_register(ViPipe,  0x774f, 0x83);
    ov2718_write_register(ViPipe,  0x7750, 0x00);
    ov2718_write_register(ViPipe,  0x7751, 0x01);
    ov2718_write_register(ViPipe,  0x7752, 0x05);
    ov2718_write_register(ViPipe,  0x7753, 0x03);
    ov2718_write_register(ViPipe,  0x7754, 0x05);
    ov2718_write_register(ViPipe,  0x7755, 0x32);
    ov2718_write_register(ViPipe,  0x7756, 0x00);
    ov2718_write_register(ViPipe,  0x7757, 0x00);
    ov2718_write_register(ViPipe,  0x7758, 0x05);
    ov2718_write_register(ViPipe,  0x7759, 0x70);
    ov2718_write_register(ViPipe,  0x775a, 0x00);
    ov2718_write_register(ViPipe,  0x775b, 0x01);
    ov2718_write_register(ViPipe,  0x775c, 0x05);
    ov2718_write_register(ViPipe,  0x775d, 0x74);
    ov2718_write_register(ViPipe,  0x775e, 0x03);
    ov2718_write_register(ViPipe,  0x775f, 0x90);
    ov2718_write_register(ViPipe,  0x7760, 0x05);
    ov2718_write_register(ViPipe,  0x7761, 0x83);
    ov2718_write_register(ViPipe,  0x7762, 0x00);
    ov2718_write_register(ViPipe,  0x7763, 0x01);
    ov2718_write_register(ViPipe,  0x7764, 0x05);
    ov2718_write_register(ViPipe,  0x7765, 0x03);
    ov2718_write_register(ViPipe,  0x7766, 0x05);
    ov2718_write_register(ViPipe,  0x7767, 0x32);
    ov2718_write_register(ViPipe,  0x7768, 0x00);
    ov2718_write_register(ViPipe,  0x7769, 0x00);
    ov2718_write_register(ViPipe,  0x776a, 0x05);
    ov2718_write_register(ViPipe,  0x776b, 0x70);
    ov2718_write_register(ViPipe,  0x776c, 0x00);
    ov2718_write_register(ViPipe,  0x776d, 0x01);
    ov2718_write_register(ViPipe,  0x776e, 0x05);
    ov2718_write_register(ViPipe,  0x776f, 0x74);
    ov2718_write_register(ViPipe,  0x7770, 0x02);
    ov2718_write_register(ViPipe,  0x7771, 0x90);
    ov2718_write_register(ViPipe,  0x7772, 0x05);
    ov2718_write_register(ViPipe,  0x7773, 0x03);
    ov2718_write_register(ViPipe,  0x7774, 0x07);
    ov2718_write_register(ViPipe,  0x7775, 0x00);
    ov2718_write_register(ViPipe,  0x7776, 0x0f);
    ov2718_write_register(ViPipe,  0x7777, 0x00);
    ov2718_write_register(ViPipe,  0x7778, 0x08);
    ov2718_write_register(ViPipe,  0x7779, 0x31);
    ov2718_write_register(ViPipe,  0x777a, 0x08);
    ov2718_write_register(ViPipe,  0x777b, 0xd2);
    ov2718_write_register(ViPipe,  0x777c, 0x0f);
    ov2718_write_register(ViPipe,  0x777d, 0x00);
    ov2718_write_register(ViPipe,  0x777e, 0x04);
    ov2718_write_register(ViPipe,  0x777f, 0xe5);
    ov2718_write_register(ViPipe,  0x7780, 0x06);
    ov2718_write_register(ViPipe,  0x7781, 0x50);
    ov2718_write_register(ViPipe,  0x7782, 0x04);
    ov2718_write_register(ViPipe,  0x7783, 0xe4);
    ov2718_write_register(ViPipe,  0x7784, 0x00);
    ov2718_write_register(ViPipe,  0x7785, 0x00);
    ov2718_write_register(ViPipe,  0x7786, 0x06);
    ov2718_write_register(ViPipe,  0x7787, 0x5c);
    ov2718_write_register(ViPipe,  0x7788, 0x09);
    ov2718_write_register(ViPipe,  0x7789, 0x15);
    ov2718_write_register(ViPipe,  0x778a, 0x06);
    ov2718_write_register(ViPipe,  0x778b, 0x1c);
    ov2718_write_register(ViPipe,  0x778c, 0x00);
    ov2718_write_register(ViPipe,  0x778d, 0x02);
    ov2718_write_register(ViPipe,  0x778e, 0x06);
    ov2718_write_register(ViPipe,  0x778f, 0xa0);
    ov2718_write_register(ViPipe,  0x7790, 0x00);
    ov2718_write_register(ViPipe,  0x7791, 0x01);
    ov2718_write_register(ViPipe,  0x7792, 0x06);
    ov2718_write_register(ViPipe,  0x7793, 0xac);
    ov2718_write_register(ViPipe,  0x7794, 0x00);
    ov2718_write_register(ViPipe,  0x7795, 0x0f);
    ov2718_write_register(ViPipe,  0x7796, 0x05);
    ov2718_write_register(ViPipe,  0x7797, 0x30);
    ov2718_write_register(ViPipe,  0x7798, 0x0f);
    ov2718_write_register(ViPipe,  0x7799, 0x00);
    ov2718_write_register(ViPipe,  0x779a, 0x00);
    ov2718_write_register(ViPipe,  0x779b, 0x00);
    ov2718_write_register(ViPipe,  0x779c, 0x00);
    ov2718_write_register(ViPipe,  0x779d, 0x02);
    ov2718_write_register(ViPipe,  0x779e, 0x04);
    ov2718_write_register(ViPipe,  0x779f, 0xe5);
    ov2718_write_register(ViPipe,  0x77a0, 0x04);
    ov2718_write_register(ViPipe,  0x77a1, 0xe4);
    ov2718_write_register(ViPipe,  0x77a2, 0x05);
    ov2718_write_register(ViPipe,  0x77a3, 0x33);
    ov2718_write_register(ViPipe,  0x77a4, 0x07);
    ov2718_write_register(ViPipe,  0x77a5, 0x10);
    ov2718_write_register(ViPipe,  0x77a6, 0x00);
    ov2718_write_register(ViPipe,  0x77a7, 0x00);
    ov2718_write_register(ViPipe,  0x77a8, 0x07);
    ov2718_write_register(ViPipe,  0x77a9, 0x00);
    ov2718_write_register(ViPipe,  0x77aa, 0x01);
    ov2718_write_register(ViPipe,  0x77ab, 0xbb);
    ov2718_write_register(ViPipe,  0x77ac, 0x07);
    ov2718_write_register(ViPipe,  0x77ad, 0x10);
    ov2718_write_register(ViPipe,  0x77ae, 0x00);
    ov2718_write_register(ViPipe,  0x77af, 0x00);
    ov2718_write_register(ViPipe,  0x77b0, 0x07);
    ov2718_write_register(ViPipe,  0x77b1, 0x00);
    ov2718_write_register(ViPipe,  0x77b2, 0x01);
    ov2718_write_register(ViPipe,  0x77b3, 0xaa);
    ov2718_write_register(ViPipe,  0x77b4, 0x07);
    ov2718_write_register(ViPipe,  0x77b5, 0x10);
    ov2718_write_register(ViPipe,  0x77b6, 0x00);
    ov2718_write_register(ViPipe,  0x77b7, 0x00);
    ov2718_write_register(ViPipe,  0x77b8, 0x07);
    ov2718_write_register(ViPipe,  0x77b9, 0x00);
    ov2718_write_register(ViPipe,  0x77ba, 0x01);
    ov2718_write_register(ViPipe,  0x77bb, 0x99);
    ov2718_write_register(ViPipe,  0x77bc, 0x07);
    ov2718_write_register(ViPipe,  0x77bd, 0x10);
    ov2718_write_register(ViPipe,  0x77be, 0x00);
    ov2718_write_register(ViPipe,  0x77bf, 0x00);
    ov2718_write_register(ViPipe,  0x77c0, 0x07);
    ov2718_write_register(ViPipe,  0x77c1, 0x00);
    ov2718_write_register(ViPipe,  0x77c2, 0x01);
    ov2718_write_register(ViPipe,  0x77c3, 0x88);
    ov2718_write_register(ViPipe,  0x77c4, 0x07);
    ov2718_write_register(ViPipe,  0x77c5, 0x10);
    ov2718_write_register(ViPipe,  0x77c6, 0x00);
    ov2718_write_register(ViPipe,  0x77c7, 0x00);
    ov2718_write_register(ViPipe,  0x77c8, 0x07);
    ov2718_write_register(ViPipe,  0x77c9, 0x00);
    ov2718_write_register(ViPipe,  0x77ca, 0x01);
    ov2718_write_register(ViPipe,  0x77cb, 0x77);
    ov2718_write_register(ViPipe,  0x77cc, 0x07);
    ov2718_write_register(ViPipe,  0x77cd, 0x10);
    ov2718_write_register(ViPipe,  0x77ce, 0x00);
    ov2718_write_register(ViPipe,  0x77cf, 0x00);
    ov2718_write_register(ViPipe,  0x77d0, 0x07);
    ov2718_write_register(ViPipe,  0x77d1, 0x00);
    ov2718_write_register(ViPipe,  0x77d2, 0x01);
    ov2718_write_register(ViPipe,  0x77d3, 0x66);
    ov2718_write_register(ViPipe,  0x77d4, 0x07);
    ov2718_write_register(ViPipe,  0x77d5, 0x10);
    ov2718_write_register(ViPipe,  0x77d6, 0x00);
    ov2718_write_register(ViPipe,  0x77d7, 0x00);
    ov2718_write_register(ViPipe,  0x77d8, 0x07);
    ov2718_write_register(ViPipe,  0x77d9, 0x00);
    ov2718_write_register(ViPipe,  0x77da, 0x01);
    ov2718_write_register(ViPipe,  0x77db, 0x55);
    ov2718_write_register(ViPipe,  0x77dc, 0x07);
    ov2718_write_register(ViPipe,  0x77dd, 0x10);
    ov2718_write_register(ViPipe,  0x77de, 0x00);
    ov2718_write_register(ViPipe,  0x77df, 0x00);
    ov2718_write_register(ViPipe,  0x77e0, 0x07);
    ov2718_write_register(ViPipe,  0x77e1, 0x00);
    ov2718_write_register(ViPipe,  0x77e2, 0x01);
    ov2718_write_register(ViPipe,  0x77e3, 0x44);
    ov2718_write_register(ViPipe,  0x77e4, 0x07);
    ov2718_write_register(ViPipe,  0x77e5, 0x10);
    ov2718_write_register(ViPipe,  0x77e6, 0x00);
    ov2718_write_register(ViPipe,  0x77e7, 0x00);
    ov2718_write_register(ViPipe,  0x77e8, 0x07);
    ov2718_write_register(ViPipe,  0x77e9, 0x00);
    ov2718_write_register(ViPipe,  0x77ea, 0x01);
    ov2718_write_register(ViPipe,  0x77eb, 0x33);
    ov2718_write_register(ViPipe,  0x77ec, 0x07);
    ov2718_write_register(ViPipe,  0x77ed, 0x10);
    ov2718_write_register(ViPipe,  0x77ee, 0x00);
    ov2718_write_register(ViPipe,  0x77ef, 0x00);
    ov2718_write_register(ViPipe,  0x77f0, 0x07);
    ov2718_write_register(ViPipe,  0x77f1, 0x00);
    ov2718_write_register(ViPipe,  0x77f2, 0x01);
    ov2718_write_register(ViPipe,  0x77f3, 0x22);
    ov2718_write_register(ViPipe,  0x77f4, 0x07);
    ov2718_write_register(ViPipe,  0x77f5, 0x10);
    ov2718_write_register(ViPipe,  0x77f6, 0x00);
    ov2718_write_register(ViPipe,  0x77f7, 0x00);
    ov2718_write_register(ViPipe,  0x77f8, 0x07);
    ov2718_write_register(ViPipe,  0x77f9, 0x00);
    ov2718_write_register(ViPipe,  0x77fa, 0x01);
    ov2718_write_register(ViPipe,  0x77fb, 0x11);
    ov2718_write_register(ViPipe,  0x77fc, 0x07);
    ov2718_write_register(ViPipe,  0x77fd, 0x10);
    ov2718_write_register(ViPipe,  0x77fe, 0x00);
    ov2718_write_register(ViPipe,  0x77ff, 0x00);
    ov2718_write_register(ViPipe,  0x7800, 0x07);
    ov2718_write_register(ViPipe,  0x7801, 0x00);
    ov2718_write_register(ViPipe,  0x7802, 0x01);
    ov2718_write_register(ViPipe,  0x7803, 0x00);
    ov2718_write_register(ViPipe,  0x7804, 0x01);
    ov2718_write_register(ViPipe,  0x7805, 0xff);
    ov2718_write_register(ViPipe,  0x7806, 0x07);
    ov2718_write_register(ViPipe,  0x7807, 0x00);
    ov2718_write_register(ViPipe,  0x7808, 0x02);
    ov2718_write_register(ViPipe,  0x7809, 0xa0);
    ov2718_write_register(ViPipe,  0x780a, 0x0f);
    ov2718_write_register(ViPipe,  0x780b, 0x00);
    ov2718_write_register(ViPipe,  0x780c, 0x08);
    ov2718_write_register(ViPipe,  0x780d, 0x36);
    ov2718_write_register(ViPipe,  0x780e, 0x06);
    ov2718_write_register(ViPipe,  0x780f, 0x50);
    ov2718_write_register(ViPipe,  0x7810, 0x04);
    ov2718_write_register(ViPipe,  0x7811, 0xe4);
    ov2718_write_register(ViPipe,  0x7812, 0x00);
    ov2718_write_register(ViPipe,  0x7813, 0x00);
    ov2718_write_register(ViPipe,  0x7814, 0x05);
    ov2718_write_register(ViPipe,  0x7815, 0x33);
    ov2718_write_register(ViPipe,  0x7816, 0x06);
    ov2718_write_register(ViPipe,  0x7817, 0x5c);
    ov2718_write_register(ViPipe,  0x7818, 0x09);
    ov2718_write_register(ViPipe,  0x7819, 0x15);
    ov2718_write_register(ViPipe,  0x781a, 0x06);
    ov2718_write_register(ViPipe,  0x781b, 0x1c);
    ov2718_write_register(ViPipe,  0x781c, 0x05);
    ov2718_write_register(ViPipe,  0x781d, 0x33);
    ov2718_write_register(ViPipe,  0x781e, 0x00);
    ov2718_write_register(ViPipe,  0x781f, 0x01);
    ov2718_write_register(ViPipe,  0x7820, 0x06);
    ov2718_write_register(ViPipe,  0x7821, 0x24);
    ov2718_write_register(ViPipe,  0x7822, 0x00);
    ov2718_write_register(ViPipe,  0x7823, 0x01);
    ov2718_write_register(ViPipe,  0x7824, 0x06);
    ov2718_write_register(ViPipe,  0x7825, 0x20);
    ov2718_write_register(ViPipe,  0x7826, 0x0f);
    ov2718_write_register(ViPipe,  0x7827, 0x00);
    ov2718_write_register(ViPipe,  0x7828, 0x08);
    ov2718_write_register(ViPipe,  0x7829, 0x36);
    ov2718_write_register(ViPipe,  0x782a, 0x07);
    ov2718_write_register(ViPipe,  0x782b, 0x10);
    ov2718_write_register(ViPipe,  0x782c, 0x00);
    ov2718_write_register(ViPipe,  0x782d, 0x00);
    ov2718_write_register(ViPipe,  0x782e, 0x07);
    ov2718_write_register(ViPipe,  0x782f, 0x00);
    ov2718_write_register(ViPipe,  0x7830, 0x01);
    ov2718_write_register(ViPipe,  0x7831, 0xbb);
    ov2718_write_register(ViPipe,  0x7832, 0x07);
    ov2718_write_register(ViPipe,  0x7833, 0x10);
    ov2718_write_register(ViPipe,  0x7834, 0x00);
    ov2718_write_register(ViPipe,  0x7835, 0x00);
    ov2718_write_register(ViPipe,  0x7836, 0x07);
    ov2718_write_register(ViPipe,  0x7837, 0x00);
    ov2718_write_register(ViPipe,  0x7838, 0x01);
    ov2718_write_register(ViPipe,  0x7839, 0xaa);
    ov2718_write_register(ViPipe,  0x783a, 0x07);
    ov2718_write_register(ViPipe,  0x783b, 0x10);
    ov2718_write_register(ViPipe,  0x783c, 0x00);
    ov2718_write_register(ViPipe,  0x783d, 0x00);
    ov2718_write_register(ViPipe,  0x783e, 0x07);
    ov2718_write_register(ViPipe,  0x783f, 0x00);
    ov2718_write_register(ViPipe,  0x7840, 0x01);
    ov2718_write_register(ViPipe,  0x7841, 0x99);
    ov2718_write_register(ViPipe,  0x7842, 0x07);
    ov2718_write_register(ViPipe,  0x7843, 0x10);
    ov2718_write_register(ViPipe,  0x7844, 0x00);
    ov2718_write_register(ViPipe,  0x7845, 0x00);
    ov2718_write_register(ViPipe,  0x7846, 0x07);
    ov2718_write_register(ViPipe,  0x7847, 0x00);
    ov2718_write_register(ViPipe,  0x7848, 0x01);
    ov2718_write_register(ViPipe,  0x7849, 0x88);
    ov2718_write_register(ViPipe,  0x784a, 0x07);
    ov2718_write_register(ViPipe,  0x784b, 0x10);
    ov2718_write_register(ViPipe,  0x784c, 0x00);
    ov2718_write_register(ViPipe,  0x784d, 0x00);
    ov2718_write_register(ViPipe,  0x784e, 0x07);
    ov2718_write_register(ViPipe,  0x784f, 0x00);
    ov2718_write_register(ViPipe,  0x7850, 0x01);
    ov2718_write_register(ViPipe,  0x7851, 0x77);
    ov2718_write_register(ViPipe,  0x7852, 0x07);
    ov2718_write_register(ViPipe,  0x7853, 0x10);
    ov2718_write_register(ViPipe,  0x7854, 0x00);
    ov2718_write_register(ViPipe,  0x7855, 0x00);
    ov2718_write_register(ViPipe,  0x7856, 0x07);
    ov2718_write_register(ViPipe,  0x7857, 0x00);
    ov2718_write_register(ViPipe,  0x7858, 0x01);
    ov2718_write_register(ViPipe,  0x7859, 0x66);
    ov2718_write_register(ViPipe,  0x785a, 0x07);
    ov2718_write_register(ViPipe,  0x785b, 0x10);
    ov2718_write_register(ViPipe,  0x785c, 0x00);
    ov2718_write_register(ViPipe,  0x785d, 0x00);
    ov2718_write_register(ViPipe,  0x785e, 0x07);
    ov2718_write_register(ViPipe,  0x785f, 0x00);
    ov2718_write_register(ViPipe,  0x7860, 0x01);
    ov2718_write_register(ViPipe,  0x7861, 0x55);
    ov2718_write_register(ViPipe,  0x7862, 0x07);
    ov2718_write_register(ViPipe,  0x7863, 0x10);
    ov2718_write_register(ViPipe,  0x7864, 0x00);
    ov2718_write_register(ViPipe,  0x7865, 0x00);
    ov2718_write_register(ViPipe,  0x7866, 0x07);
    ov2718_write_register(ViPipe,  0x7867, 0x00);
    ov2718_write_register(ViPipe,  0x7868, 0x01);
    ov2718_write_register(ViPipe,  0x7869, 0x44);
    ov2718_write_register(ViPipe,  0x786a, 0x07);
    ov2718_write_register(ViPipe,  0x786b, 0x10);
    ov2718_write_register(ViPipe,  0x786c, 0x00);
    ov2718_write_register(ViPipe,  0x786d, 0x00);
    ov2718_write_register(ViPipe,  0x786e, 0x07);
    ov2718_write_register(ViPipe,  0x786f, 0x00);
    ov2718_write_register(ViPipe,  0x7870, 0x01);
    ov2718_write_register(ViPipe,  0x7871, 0x33);
    ov2718_write_register(ViPipe,  0x7872, 0x07);
    ov2718_write_register(ViPipe,  0x7873, 0x10);
    ov2718_write_register(ViPipe,  0x7874, 0x00);
    ov2718_write_register(ViPipe,  0x7875, 0x00);
    ov2718_write_register(ViPipe,  0x7876, 0x07);
    ov2718_write_register(ViPipe,  0x7877, 0x00);
    ov2718_write_register(ViPipe,  0x7878, 0x01);
    ov2718_write_register(ViPipe,  0x7879, 0x22);
    ov2718_write_register(ViPipe,  0x787a, 0x07);
    ov2718_write_register(ViPipe,  0x787b, 0x10);
    ov2718_write_register(ViPipe,  0x787c, 0x00);
    ov2718_write_register(ViPipe,  0x787d, 0x00);
    ov2718_write_register(ViPipe,  0x787e, 0x07);
    ov2718_write_register(ViPipe,  0x787f, 0x00);
    ov2718_write_register(ViPipe,  0x7880, 0x01);
    ov2718_write_register(ViPipe,  0x7881, 0x11);
    ov2718_write_register(ViPipe,  0x7882, 0x07);
    ov2718_write_register(ViPipe,  0x7883, 0x10);
    ov2718_write_register(ViPipe,  0x7884, 0x00);
    ov2718_write_register(ViPipe,  0x7885, 0x00);
    ov2718_write_register(ViPipe,  0x7886, 0x07);
    ov2718_write_register(ViPipe,  0x7887, 0x00);
    ov2718_write_register(ViPipe,  0x7888, 0x01);
    ov2718_write_register(ViPipe,  0x7889, 0x00);
    ov2718_write_register(ViPipe,  0x788a, 0x01);
    ov2718_write_register(ViPipe,  0x788b, 0xff);
    ov2718_write_register(ViPipe,  0x788c, 0x02);
    ov2718_write_register(ViPipe,  0x788d, 0xa0);
    ov2718_write_register(ViPipe,  0x788e, 0x0f);
    ov2718_write_register(ViPipe,  0x788f, 0x00);
    ov2718_write_register(ViPipe,  0x7890, 0x08);
    ov2718_write_register(ViPipe,  0x7891, 0x3b);
    ov2718_write_register(ViPipe,  0x7892, 0x08);
    ov2718_write_register(ViPipe,  0x7893, 0x5e);
    ov2718_write_register(ViPipe,  0x7894, 0x0f);
    ov2718_write_register(ViPipe,  0x7895, 0x00);
    ov2718_write_register(ViPipe,  0x7896, 0x04);
    ov2718_write_register(ViPipe,  0x7897, 0xc0);
    ov2718_write_register(ViPipe,  0x7898, 0x09);
    ov2718_write_register(ViPipe,  0x7899, 0x15);
    ov2718_write_register(ViPipe,  0x789a, 0x04);
    ov2718_write_register(ViPipe,  0x789b, 0x99);
    ov2718_write_register(ViPipe,  0x789c, 0x07);
    ov2718_write_register(ViPipe,  0x789d, 0x14);
    ov2718_write_register(ViPipe,  0x789e, 0x04);
    ov2718_write_register(ViPipe,  0x789f, 0x80);
    ov2718_write_register(ViPipe,  0x78a0, 0x04);
    ov2718_write_register(ViPipe,  0x78a1, 0xa4);
    ov2718_write_register(ViPipe,  0x78a2, 0x00);
    ov2718_write_register(ViPipe,  0x78a3, 0x0a);
    ov2718_write_register(ViPipe,  0x78a4, 0x04);
    ov2718_write_register(ViPipe,  0x78a5, 0xa6);
    ov2718_write_register(ViPipe,  0x78a6, 0x00);
    ov2718_write_register(ViPipe,  0x78a7, 0x00);
    ov2718_write_register(ViPipe,  0x78a8, 0x04);
    ov2718_write_register(ViPipe,  0x78a9, 0xa0);
    ov2718_write_register(ViPipe,  0x78aa, 0x04);
    ov2718_write_register(ViPipe,  0x78ab, 0x80);
    ov2718_write_register(ViPipe,  0x78ac, 0x04);
    ov2718_write_register(ViPipe,  0x78ad, 0x00);
    ov2718_write_register(ViPipe,  0x78ae, 0x05);
    ov2718_write_register(ViPipe,  0x78af, 0x03);
    ov2718_write_register(ViPipe,  0x78b0, 0x06);
    ov2718_write_register(ViPipe,  0x78b1, 0x00);
    ov2718_write_register(ViPipe,  0x78b2, 0x0f);
    ov2718_write_register(ViPipe,  0x78b3, 0x00);
    ov2718_write_register(ViPipe,  0x78b4, 0x0f);
    ov2718_write_register(ViPipe,  0x78b5, 0x00);
    ov2718_write_register(ViPipe,  0x78b6, 0x0f);
    ov2718_write_register(ViPipe,  0x78b7, 0x00);
    ov2718_write_register(ViPipe,  0x30b0, 0x08);
    ov2718_write_register(ViPipe,  0x30b1, 0x98);
    ov2718_write_register(ViPipe,  0x30b2, 0x04);
    ov2718_write_register(ViPipe,  0x30b3, 0x70);
    ov2718_write_register(ViPipe,  0x3197, 0x00);
    ov2718_write_register(ViPipe,  0x3195, 0x28);
    ov2718_write_register(ViPipe,  0x315a, 0x02);
    ov2718_write_register(ViPipe,  0x315b, 0x00);
    ov2718_write_register(ViPipe,  0x304b, 0x00);
    ov2718_write_register(ViPipe,  0x304d, 0xa4);
    ov2718_write_register(ViPipe,  0x3033, 0x30);

    ov2718_write_register(ViPipe,  0X30bb, 0X04);
    ov2718_write_register(ViPipe,  0X315a, 0X02);
    ov2718_write_register(ViPipe,  0X315b, 0X00);
    ov2718_write_register(ViPipe,  0X315c, 0X01);
    ov2718_write_register(ViPipe,  0X315d, 0X80);
    ov2718_write_register(ViPipe,  0X315e, 0X02);
    ov2718_write_register(ViPipe,  0X315f, 0X86);
    ov2718_default_reg_init(ViPipe);
    ov2718_write_register(ViPipe,  0x3012, 0x01);

    printf("ov2718 sensor 2wdr1 init sucessful \n");
    return;

}
